Skip to content

Instantly share code, notes, and snippets.

View GroovyGab's full-sized avatar
🌏
localhost

gabb GroovyGab

🌏
localhost
View GitHub Profile
@Allvaa
Allvaa / ExtendedMessage.js
Last active December 17, 2023 23:41
Discord.js v12 Inline Replies
View ExtendedMessage.js
const { APIMessage, Structures } = require("discord.js");
class ExtAPIMessage extends APIMessage {
resolveData() {
if (this.data) return this;
super.resolveData();
const allowedMentions = this.options.allowedMentions || this.target.client.options.allowedMentions || {};
if (allowedMentions.repliedUser !== undefined) {
if (this.data.allowed_mentions === undefined) this.data.allowed_mentions = {};
Object.assign(this.data.allowed_mentions, { replied_user: allowedMentions.repliedUser });
@fantattitude
fantattitude / gist:3627354
Created September 4, 2012 22:21
Spotify URL Regexp
View gist:3627354
spotifyReg = /(https?:\/\/open.spotify.com\/(track|user|artist|album)\/[a-zA-Z0-9]+(\/playlist\/[a-zA-Z0-9]+|)|spotify:(track|user|artist|album):[a-zA-Z0-9]+(:playlist:[a-zA-Z0-9]+|))/