diff --git a/README.md b/README.md index b146ead..5ba8b31 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ # bop-js -A small private music bot using [discord-player](https://discord-player.js.org) and [discord.js](https://discord.js.org) v13 +A small private music bot using [distube](https://distube.js.org) and [discord.js](https://discord.js.org) v13 Create a .env file with a TOKEN variable. Then build the project with `npm run build` diff --git a/lib/Client.ts b/lib/Client.ts index 25b3c9c..200cfb3 100644 --- a/lib/Client.ts +++ b/lib/Client.ts @@ -1,14 +1,24 @@ -import { Player } from "discord-player"; +import SpotifyPlugin from "@distube/spotify"; +import SoundCloudPlugin from "@distube/soundcloud"; +import DisTube from "distube"; import { Client, Intents } from "discord.js"; import { CommandStore, EventStore, InhibitorStore } from "./Stores"; import BopConsole from "./util/Console"; export default class BopClient extends Client { public prefix = "bop!"; - public player: Player = new Player(this, { + public player: DisTube = new DisTube(this, { + searchSongs: 1, + searchCooldown: 5, + leaveOnEmpty: false, + leaveOnFinish: true, + leaveOnStop: true, + nsfw: true, + emitNewSongOnly: true, ytdlOptions: { filter: "audioonly", }, + plugins: [new SoundCloudPlugin(), new SpotifyPlugin()], }); public commands: CommandStore = new CommandStore(this, "../src/commands"); public events: EventStore = new EventStore(this, "../src/events"); @@ -28,6 +38,13 @@ export default class BopClient extends Client { }); } + public hasMention(message: string) { + return ( + message.startsWith(`<@!${this.user?.id}>`) || + message.startsWith(`<@${this.user?.id}>`) + ); + } + public async start(): Promise { this.events.setEmitters({ client: this, player: this.player }); diff --git a/lib/Modules.ts b/lib/Modules.ts index b6f7bf9..4487e57 100644 --- a/lib/Modules.ts +++ b/lib/Modules.ts @@ -1,4 +1,4 @@ -import { Awaited, Message } from "discord.js"; +import { Message } from "discord.js"; import { sep } from "path"; import BopClient from "./Client"; @@ -71,7 +71,7 @@ class Event extends Module { this.once = options.once ?? false; } - public main(...args: readonly unknown[]): Awaited { + public main(...args: readonly unknown[]): void { throw new Error("Not implemented"); } } diff --git a/lib/util/Console.ts b/lib/util/Console.ts index 120bee5..f0f9e56 100644 --- a/lib/util/Console.ts +++ b/lib/util/Console.ts @@ -3,46 +3,36 @@ import { Console } from "console"; import { inspect } from "util"; export default class BopConsole extends Console { - constructor() { - super(process.stdout, process.stderr); - } - - get timestamp(): string { - return new Date().toLocaleTimeString(); - } + constructor() { + super(process.stdout, process.stderr); + } - public log(message: unknown): void { - this.write(message, ["inverse"]); - } + get timestamp(): string { + return new Date().toLocaleTimeString(); + } - public success(message: unknown): void { - this.write(message, ["bgGreen", "bold"]); - } + public log(message: unknown): void { + this.write(message, ["inverse"]); + } - public error(message: unknown): void { - this.write(message, ["red", "underline"]); - } + public success(message: unknown): void { + this.write(message, ["bgGreen", "bold"]); + } - public info(message: unknown): void { - this.write(message, ["bgBlue", "dim"]); - } + public error(message: unknown): void { + this.write(message, ["red", "underline"], "error"); + } - private write(message: unknown, colors: string[], type?: string): void { - const flattened = this._flatten(message); - const colorsTemplate = colors.join("."); - super[type === "error" ? "error" : "log"]( - chalk`{${colorsTemplate} ${flattened} | ${this.timestamp}}` - ); - } + public info(message: unknown): void { + this.write(message, ["bgBlue", "dim"]); + } - private _flatten(message: unknown): string { - if (Array.isArray(message)) { - return message.every((entry) => typeof entry === "string") - ? message.join("\n") - : message.map((e) => inspect(e)).join("\n"); - } else if (typeof message === "object") { - return inspect(message); + private write(message: unknown, colors: string[], type?: string): void { + const colorsTemplate = colors.join("."); + super[type === "error" ? "error" : "log"]( + chalk`{${colorsTemplate} ${ + typeof message === "string" ? message : inspect(message) + } | ${this.timestamp}}` + ); } - return String(message); - } } diff --git a/lib/util/Embeds.ts b/lib/util/Embeds.ts index 92797c8..34eece0 100644 --- a/lib/util/Embeds.ts +++ b/lib/util/Embeds.ts @@ -1,4 +1,4 @@ -import { Playlist, Track } from "discord-player"; +import { Playlist, Song } from "distube"; import { MessageEmbed } from "discord.js"; export const EMBED_COLOR = "BLUE"; @@ -12,28 +12,23 @@ export class Notification extends MessageEmbed { } export class MusicEmbed extends MessageEmbed { - constructor(music: Playlist | Track, nowplaying = false) { - const author = - music instanceof Playlist - ? music.tracks[0].requestedBy - : music.requestedBy; - + constructor(music: Playlist | Song, nowplaying = false) { const description = - music instanceof Track - ? `${nowplaying ? "Now playing" : "Added"} **[${music.title}](${ + music instanceof Song + ? `${nowplaying ? "Now playing" : "Added"} **[${music.name}](${ music.url - })** by **${music.author}** | **[${music.duration}]**` - : `Added **${music.tracks.length}** tracks from **[${music.title}](${music.url})** by **[${music.author.name}](${music.author.url})**`; + })** by **[${music.uploader.name}](${music.uploader.url})**` + : `Added **${music.songs.length}** tracks from **[${music.name}](${music.url})**`; super({ - description: description, + description: `${description} | **[${music.formattedDuration}]**`, color: EMBED_COLOR, thumbnail: { url: music.thumbnail, }, author: { - name: author.username, - icon_url: author.avatarURL()!, + name: music.user?.username, + icon_url: music.user?.avatarURL() as string, }, }); } diff --git a/lib/util/Util.ts b/lib/util/Util.ts index 44c59df..0ca722c 100644 --- a/lib/util/Util.ts +++ b/lib/util/Util.ts @@ -1,4 +1,3 @@ -import { AudioFilters } from "discord-player"; import { MessageActionRow, MessageButton, TextChannel } from "discord.js"; export interface QueueMetadata { @@ -7,34 +6,28 @@ export interface QueueMetadata { } export default class Util { - public static toTitleCase(e: string): string { - return `${e.charAt(0).toUpperCase()}${e.slice(1)}`; - } + public static toTitleCase(e: string): string { + return `${e.charAt(0).toUpperCase()}${e.slice(1)}`; + } - public static get defaultFilters(): Record { - const filters: Record = {}; - AudioFilters.names.map((f) => (filters[f] = false)); - return filters; - } - - public static buildDefaultActionRow(): MessageActionRow { - return new MessageActionRow().addComponents( - new MessageButton() - .setCustomId("resume") - .setLabel("Resume") - .setStyle("SUCCESS"), - new MessageButton() - .setCustomId("pause") - .setLabel("Pause") - .setStyle("DANGER"), - new MessageButton() - .setCustomId("nowplaying") - .setLabel("Now Playing") - .setStyle("PRIMARY"), - new MessageButton() - .setCustomId("queue") - .setLabel("Queue") - .setStyle("SECONDARY") - ); - } + public static buildDefaultActionRow(): MessageActionRow { + return new MessageActionRow().addComponents( + new MessageButton() + .setCustomId("resume") + .setLabel("Resume") + .setStyle("SUCCESS"), + new MessageButton() + .setCustomId("pause") + .setLabel("Pause") + .setStyle("DANGER"), + new MessageButton() + .setCustomId("nowplaying") + .setLabel("Now Playing") + .setStyle("PRIMARY"), + new MessageButton() + .setCustomId("queue") + .setLabel("Queue") + .setStyle("SECONDARY") + ); + } } diff --git a/package-lock.json b/package-lock.json index 684cf54..c2d6b45 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,15 +9,15 @@ "version": "1.0.0", "license": "ISC", "dependencies": { - "@discordjs/opus": "^0.6.0", + "@discordjs/opus": "^0.5.3", "@discordjs/voice": "^0.6.0", - "chalk": "^4.1.2", - "discord-player": "^5.1.0", - "discord-ytdl-core": "^5.0.4", - "discord.js": "^13.1.0", + "@distube/soundcloud": "^0.2.2", + "@distube/spotify": "^0.6.4", + "discord.js": "^13.2.0", + "distube": "^3.0.0-beta.39", "dotenv": "^10.0.0", "ffmpeg-static": "^4.4.0", - "ytdl-core": "^4.9.1" + "libsodium-wrappers": "^0.7.9" }, "devDependencies": { "@typescript-eslint/eslint-plugin": "^4.31.1", @@ -148,15 +148,15 @@ } }, "node_modules/@discordjs/builders": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/@discordjs/builders/-/builders-0.5.0.tgz", - "integrity": "sha512-HP5y4Rqw68o61Qv4qM5tVmDbWi4mdTFftqIOGRo33SNPpLJ1Ga3KEIR2ibKofkmsoQhEpLmopD1AZDs3cKpHuw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/@discordjs/builders/-/builders-0.6.0.tgz", + "integrity": "sha512-mH3Gx61LKk2CD05laCI9K5wp+a3NyASHDUGx83DGJFkqJlRlSV5WMJNY6RS37A5SjqDtGMF4wVR9jzFaqShe6Q==", "dependencies": { "@sindresorhus/is": "^4.0.1", "discord-api-types": "^0.22.0", "ow": "^0.27.0", "ts-mixer": "^6.0.0", - "tslib": "^2.3.0" + "tslib": "^2.3.1" }, "engines": { "node": ">=14.0.0", @@ -204,13 +204,13 @@ } }, "node_modules/@discordjs/opus": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/@discordjs/opus/-/opus-0.6.0.tgz", - "integrity": "sha512-Xuw8OP9BJgObEBs/SgxixnKj+y+w9st45uOAJ+cGegUGwxAIR4J7sQt3Y1J3G9SGGe82+MTxvy7sg1/QUkigcg==", + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/@discordjs/opus/-/opus-0.5.3.tgz", + "integrity": "sha512-IQhCwCy2WKXLe+qkOkwO1Wjgk20uqeAbqM62tCbzIqbTsXX4YAge8Me9RFnI77Lx+UTkgm4rSVM3VPVdS/GsUw==", "hasInstallScript": true, "dependencies": { - "@discordjs/node-pre-gyp": "^0.4.1", - "node-addon-api": "^4.0.0" + "@discordjs/node-pre-gyp": "^0.4.0", + "node-addon-api": "^3.2.1" }, "engines": { "node": ">=12.0.0" @@ -231,6 +231,84 @@ "node": ">=16.0.0" } }, + "node_modules/@distube/soundcloud": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/@distube/soundcloud/-/soundcloud-0.2.2.tgz", + "integrity": "sha512-N5bBP+KmJ3QmcZBn/LPnk+oMl5AIOwSvB5rfyuKhKn6sRaxMdI0VmyKgAbnZz17vS3LLRAKAr4BFYleflTpRhA==", + "dependencies": { + "soundcloud.ts": "^0.4.1" + }, + "peerDependencies": { + "distube": "^3.0.0-beta.34" + } + }, + "node_modules/@distube/spotify": { + "version": "0.6.4", + "resolved": "https://registry.npmjs.org/@distube/spotify/-/spotify-0.6.4.tgz", + "integrity": "sha512-MhmhLmWv9ipBJhRvQ6S1wtWL5cOuWhl89NBGcoc4AlvHOgnydVOuY7+DKOua+JSyiDXlI6qRPeyLQNfx/AtgRg==", + "dependencies": { + "spotify-uri": "^2.2.0", + "spotify-url-info": "^2.2.3", + "spotify-web-api-node": "^5.0.2" + }, + "peerDependencies": { + "distube": "^3.0.0-beta.35" + } + }, + "node_modules/@distube/youtube-dl": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/@distube/youtube-dl/-/youtube-dl-2.2.2.tgz", + "integrity": "sha512-r/+nt1Cvx6OIp0xI2NqtUMpVfavlmRN/7J379h7At6XAzfNMYn8dQcZZcgH0ErNE19rvFefQ0b0mGj/vwzp0kA==", + "hasInstallScript": true, + "dependencies": { + "dargs": "~7.0.0", + "execa": "~5.1.1", + "get-stream": "~6.0.1", + "got": "~11.8.2", + "is-unix": "~1.0.0", + "mkdirp": "~1.0.4", + "p-event": "~4.2.0", + "p-reflect": "~2.1.0" + }, + "engines": { + "node": ">= 12" + } + }, + "node_modules/@distube/ytdl-core": { + "version": "4.9.3", + "resolved": "https://registry.npmjs.org/@distube/ytdl-core/-/ytdl-core-4.9.3.tgz", + "integrity": "sha512-oj/XoIvY2Vc7eySHvbschqPNU4gFNkF9s5er1eljGzcBC5TP+ygt/TAo59yOJEZJe5gTsaIvbv/4W6IKCuBUPg==", + "dependencies": { + "m3u8stream": "^0.8.3", + "miniget": "^4.0.0", + "sax": "^1.1.3" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@distube/ytpl": { + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/@distube/ytpl/-/ytpl-1.0.12.tgz", + "integrity": "sha512-Iv6qZpUkyL+R2KQhfuvmYnqlMX+n8ts44aZ3hZUJI2dAV7lCZdsRs5MAf7oOSfZrTLL4GMNex8RGmBarm7iHtg==", + "dependencies": { + "miniget": "^4.2.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@distube/ytsr": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/@distube/ytsr/-/ytsr-1.1.5.tgz", + "integrity": "sha512-nSYsB+UYw0FXSivJ49MGkES41Gfg5rgavil9nOHra0yCsGiY4qsDzpoFVjCmbpKQ6GDUq4Z/8LOwZakgpH3N1A==", + "dependencies": { + "miniget": "^4.2.1" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/@eslint/eslintrc": { "version": "0.4.3", "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-0.4.3.tgz", @@ -307,18 +385,18 @@ } }, "node_modules/@sapphire/async-queue": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/@sapphire/async-queue/-/async-queue-1.1.4.tgz", - "integrity": "sha512-fFrlF/uWpGOX5djw5Mu2Hnnrunao75WGey0sP0J3jnhmrJ5TAPzHYOmytD5iN/+pMxS+f+u/gezqHa9tPhRHEA==", + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/@sapphire/async-queue/-/async-queue-1.1.6.tgz", + "integrity": "sha512-M5CbgMgesemMUCQo5G/InGHvp+GZx6uuJNV1iwvSWD8EFNVrfxaTcqhcAXM3MPYkjlxvNnoDNk0R1lfzvca6LA==", "engines": { - "node": ">=14", - "npm": ">=6" + "node": ">=v14.18.0", + "npm": ">=7.24.2" } }, "node_modules/@sindresorhus/is": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.1.0.tgz", - "integrity": "sha512-Cgva8HxclecUCmAImsWsbZGUh6p5DSzQ8l2Uzxuj9ANiD7LVhLM1UJ2hX/R2Y+ILpvqgW9QjmTCaBkXtj8+UOg==", + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.2.0.tgz", + "integrity": "sha512-VkE3KLBmJwcCaVARtQpfuKcKv8gcBmUubrfHGF84dXuuW6jgsRYxPtzcIhPyK9WAPpRt2/xY6zkD9MnRaJzSyw==", "engines": { "node": ">=10" }, @@ -326,16 +404,59 @@ "url": "https://github.com/sindresorhus/is?sponsor=1" } }, + "node_modules/@szmarczak/http-timer": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/@szmarczak/http-timer/-/http-timer-4.0.6.tgz", + "integrity": "sha512-4BAffykYOgO+5nzBWYwE3W90sBgLJoUPRWWcL8wlyiM8IB8ipJz3UMJ9KXQd1RKQXpKp8Tutn80HZtWsu2u76w==", + "dependencies": { + "defer-to-connect": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@types/cacheable-request": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/@types/cacheable-request/-/cacheable-request-6.0.2.tgz", + "integrity": "sha512-B3xVo+dlKM6nnKTcmm5ZtY/OL8bOAOd2Olee9M1zft65ox50OzjEHW91sDiU9j6cvW8Ejg1/Qkf4xd2kugApUA==", + "dependencies": { + "@types/http-cache-semantics": "*", + "@types/keyv": "*", + "@types/node": "*", + "@types/responselike": "*" + } + }, + "node_modules/@types/http-cache-semantics": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@types/http-cache-semantics/-/http-cache-semantics-4.0.1.tgz", + "integrity": "sha512-SZs7ekbP8CN0txVG2xVRH6EgKmEm31BOxA07vkFaETzZz1xh+cbt8BcI0slpymvwhx5dlFnQG2rTlPVQn+iRPQ==" + }, "node_modules/@types/json-schema": { "version": "7.0.9", "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.9.tgz", "integrity": "sha512-qcUXuemtEu+E5wZSJHNxUXeCZhAfXKQ41D+duX+VYPde7xyEVZci+/oXKJL13tnRs9lR2pr4fod59GT6/X1/yQ==", "dev": true }, + "node_modules/@types/keyv": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@types/keyv/-/keyv-3.1.3.tgz", + "integrity": "sha512-FXCJgyyN3ivVgRoml4h94G/p3kY+u/B86La+QptcqJaWtBWtmc6TtkNfS40n9bIvyLteHh7zXOtgbobORKPbDg==", + "dependencies": { + "@types/node": "*" + } + }, "node_modules/@types/node": { - "version": "16.9.1", - "resolved": "https://registry.npmjs.org/@types/node/-/node-16.9.1.tgz", - "integrity": "sha512-QpLcX9ZSsq3YYUUnD3nFDY8H7wctAhQj/TFKL8Ya8v5fMm3CFXxo8zStsLAl780ltoYoo1WvKUVGBQK+1ifr7g==" + "version": "16.10.4", + "resolved": "https://registry.npmjs.org/@types/node/-/node-16.10.4.tgz", + "integrity": "sha512-EITwVTX5B4nDjXjGeQAfXOrm+Jn+qNjDmyDRtWoD+wZsl/RDPRTFRKivs4Mt74iOFlLOrE5+Kf+p5yjyhm3+cA==" + }, + "node_modules/@types/responselike": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@types/responselike/-/responselike-1.0.0.tgz", + "integrity": "sha512-85Y2BjiufFzaMIlvJDvTTB8Fxl2xfLo4HgmHzVBz08w4wDePCTjYw66PdrolO0kzli3yam/YCgRufyo1DdQVTA==", + "dependencies": { + "@types/node": "*" + } }, "node_modules/@types/ws": { "version": "7.4.7", @@ -636,6 +757,7 @@ "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, "dependencies": { "color-convert": "^2.0.1" }, @@ -708,16 +830,19 @@ "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=" }, + "node_modules/axios": { + "version": "0.21.4", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.21.4.tgz", + "integrity": "sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg==", + "dependencies": { + "follow-redirects": "^1.14.0" + } + }, "node_modules/balanced-match": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" }, - "node_modules/boolbase": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", - "integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24=" - }, "node_modules/brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -744,6 +869,57 @@ "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" }, + "node_modules/cacheable-lookup": { + "version": "5.0.4", + "resolved": "https://registry.npmjs.org/cacheable-lookup/-/cacheable-lookup-5.0.4.tgz", + "integrity": "sha512-2/kNscPhpcxrOigMZzbiWF7dz8ilhb/nIHU3EyZiXWXpeq/au8qJ8VhdftMkty3n7Gj6HIGalQG8oiBNB3AJgA==", + "engines": { + "node": ">=10.6.0" + } + }, + "node_modules/cacheable-request": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/cacheable-request/-/cacheable-request-7.0.2.tgz", + "integrity": "sha512-pouW8/FmiPQbuGpkXQ9BAPv/Mo5xDGANgSNXzTzJ8DrKGuXOssM4wIQRjfanNRh3Yu5cfYPvcorqbhg2KIJtew==", + "dependencies": { + "clone-response": "^1.0.2", + "get-stream": "^5.1.0", + "http-cache-semantics": "^4.0.0", + "keyv": "^4.0.0", + "lowercase-keys": "^2.0.0", + "normalize-url": "^6.0.1", + "responselike": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/cacheable-request/node_modules/get-stream": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", + "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", + "dependencies": { + "pump": "^3.0.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "dependencies": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/callsites": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", @@ -761,6 +937,7 @@ "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -772,41 +949,6 @@ "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/cheerio": { - "version": "1.0.0-rc.10", - "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.0.0-rc.10.tgz", - "integrity": "sha512-g0J0q/O6mW8z5zxQ3A8E8J1hUgp4SMOvEoW/x84OwyHKe/Zccz83PVT4y5Crcr530FV6NgmKI1qvGTKVl9XXVw==", - "dependencies": { - "cheerio-select": "^1.5.0", - "dom-serializer": "^1.3.2", - "domhandler": "^4.2.0", - "htmlparser2": "^6.1.0", - "parse5": "^6.0.1", - "parse5-htmlparser2-tree-adapter": "^6.0.1", - "tslib": "^2.2.0" - }, - "engines": { - "node": ">= 6" - }, - "funding": { - "url": "https://github.com/cheeriojs/cheerio?sponsor=1" - } - }, - "node_modules/cheerio-select": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/cheerio-select/-/cheerio-select-1.5.0.tgz", - "integrity": "sha512-qocaHPv5ypefh6YNxvnbABM07KMxExbtbfuJoIie3iZXX1ERwYmJcIiRrr9H05ucQP1k28dav8rpdDgjQd8drg==", - "dependencies": { - "css-select": "^4.1.3", - "css-what": "^5.0.1", - "domelementtype": "^2.2.0", - "domhandler": "^4.2.0", - "domutils": "^2.7.0" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" - } - }, "node_modules/chownr": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz", @@ -815,10 +957,19 @@ "node": ">=10" } }, + "node_modules/clone-response": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/clone-response/-/clone-response-1.0.2.tgz", + "integrity": "sha1-0dyXOSAxTfZ/vrlCI7TuNQI56Ws=", + "dependencies": { + "mimic-response": "^1.0.0" + } + }, "node_modules/color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, "dependencies": { "color-name": "~1.1.4" }, @@ -829,7 +980,8 @@ "node_modules/color-name": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true }, "node_modules/color-support": { "version": "1.1.3", @@ -850,6 +1002,11 @@ "node": ">= 0.8" } }, + "node_modules/component-emitter": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.3.0.tgz", + "integrity": "sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg==" + }, "node_modules/concat-map": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", @@ -874,6 +1031,11 @@ "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=" }, + "node_modules/cookiejar": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/cookiejar/-/cookiejar-2.1.3.tgz", + "integrity": "sha512-JxbCBUdrfr6AQjOXrxoTvAMJO4HBTUIlBzslcJPAz+/KT8yk53fXun51u+RenNYvad/+Vc2DIz5o9UxlCDymFQ==" + }, "node_modules/core-util-is": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", @@ -899,7 +1061,6 @@ "version": "7.0.3", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", - "dev": true, "dependencies": { "path-key": "^3.1.0", "shebang-command": "^2.0.0", @@ -909,30 +1070,12 @@ "node": ">= 8" } }, - "node_modules/css-select": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.1.3.tgz", - "integrity": "sha512-gT3wBNd9Nj49rAbmtFHj1cljIAOLYSX1nZ8CB7TBO3INYckygm5B7LISU/szY//YmdiSLbJvDLOx9VnMVpMBxA==", - "dependencies": { - "boolbase": "^1.0.0", - "css-what": "^5.0.0", - "domhandler": "^4.2.0", - "domutils": "^2.6.0", - "nth-check": "^2.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" - } - }, - "node_modules/css-what": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/css-what/-/css-what-5.0.1.tgz", - "integrity": "sha512-FYDTSHb/7KXsWICVsxdmiExPjCfRC4qRFBdVwv7Ax9hMnvMmEjP9RfxTEZ3qPZGmADDn2vAKSo9UcN1jKVYscg==", + "node_modules/dargs": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/dargs/-/dargs-7.0.0.tgz", + "integrity": "sha512-2iy1EkLdlBzQGvbweYRFxmFath8+K7+AKB0TlhHWkNuH+TmovaMH/Wp7V7R4u7f4SnX3OgLsU9t1NI9ioDnUpg==", "engines": { - "node": ">= 6" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" + "node": ">=8" } }, "node_modules/debug": { @@ -951,12 +1094,45 @@ } } }, + "node_modules/decompress-response": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", + "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", + "dependencies": { + "mimic-response": "^3.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/decompress-response/node_modules/mimic-response": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", + "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/deep-is": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", "dev": true }, + "node_modules/defer-to-connect": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/defer-to-connect/-/defer-to-connect-2.0.1.tgz", + "integrity": "sha512-4tvttepXG1VaYGrRibk5EwJd1t4udunSOVMdLSAL6mId1ix438oPwPZMALY41FCijukO1L0twNcGsdzS7dHgDg==", + "engines": { + "node": ">=10" + } + }, "node_modules/delayed-stream": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", @@ -1001,116 +1177,120 @@ "node": ">=12" } }, - "node_modules/discord-player": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/discord-player/-/discord-player-5.1.0.tgz", - "integrity": "sha512-Rp+A/k8sm3h+MfTxhdGZjFsEK26lf5YcyBhiLgEGvh/aRRxw7z9+twnIyEPHQC8gtTiZHlfHD7ihztKFT/XJCQ==", - "dependencies": { - "@discordjs/voice": "^0.6.0", - "discord-ytdl-core": "^5.0.4", - "libsodium-wrappers": "^0.7.9", - "soundcloud-scraper": "^5.0.2", - "spotify-url-info": "^2.2.3", - "tiny-typed-emitter": "^2.1.0", - "youtube-sr": "^4.1.7", - "ytdl-core": "^4.9.1" - }, - "funding": { - "url": "https://github.com/Androz2091/discord-player?sponsor=1" - } - }, - "node_modules/discord-ytdl-core": { - "version": "5.0.4", - "resolved": "https://registry.npmjs.org/discord-ytdl-core/-/discord-ytdl-core-5.0.4.tgz", - "integrity": "sha512-O+G9wuCw5TERR9iHZFMYnYQbs/ZGudDc9cxa1OKSV5TdcBYrHGS1JqvE90ZvSQ6SmS4XvqtOf/Okls6yiGJ3sg==", - "dependencies": { - "prism-media": "^1.2.9" - }, - "funding": { - "type": "individual", - "url": "https://paypal.me/devsnowflake" - } - }, "node_modules/discord.js": { - "version": "13.1.0", - "resolved": "https://registry.npmjs.org/discord.js/-/discord.js-13.1.0.tgz", - "integrity": "sha512-gxO4CXKdHpqA+WKG+f5RNnd3srTDj5uFJHgOathksDE90YNq/Qijkd2WlMgTTMS6AJoEnHxI7G9eDQHCuZ+xDA==", + "version": "13.2.0", + "resolved": "https://registry.npmjs.org/discord.js/-/discord.js-13.2.0.tgz", + "integrity": "sha512-nyxUvL8wuQG38zx13wUMkpcA8koFszyiXdkSLwwM9opKW2LC2H5gD0cTZxImeJ6GtEnKPWT8xBiE8lLBmbNIhw==", "dependencies": { - "@discordjs/builders": "^0.5.0", + "@discordjs/builders": "^0.6.0", "@discordjs/collection": "^0.2.1", "@discordjs/form-data": "^3.0.1", - "@sapphire/async-queue": "^1.1.4", - "@types/ws": "^7.4.7", - "discord-api-types": "^0.22.0", + "@sapphire/async-queue": "^1.1.5", + "@types/ws": "^8.2.0", + "discord-api-types": "^0.23.1", "node-fetch": "^2.6.1", - "ws": "^7.5.1" + "ws": "^8.2.3" }, "engines": { "node": ">=16.6.0", "npm": ">=7.0.0" } }, - "node_modules/doctrine": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", - "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", - "dev": true, + "node_modules/discord.js/node_modules/@types/ws": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.2.0.tgz", + "integrity": "sha512-cyeefcUCgJlEk+hk2h3N+MqKKsPViQgF5boi9TTHSK+PoR9KWBb/C5ccPcDyAqgsbAYHTwulch725DV84+pSpg==", "dependencies": { - "esutils": "^2.0.2" - }, - "engines": { - "node": ">=6.0.0" + "@types/node": "*" } }, - "node_modules/dom-serializer": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.3.2.tgz", - "integrity": "sha512-5c54Bk5Dw4qAxNOI1pFEizPSjVsx5+bpJKmL2kPn8JhBUq2q09tTCa3mjijun2NfK78NMouDYNMBkOrPZiS+ig==", - "dependencies": { - "domelementtype": "^2.0.1", - "domhandler": "^4.2.0", - "entities": "^2.0.0" - }, - "funding": { - "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + "node_modules/discord.js/node_modules/discord-api-types": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.23.1.tgz", + "integrity": "sha512-igWmn+45mzXRWNEPU25I/pr8MwxHb767wAr51oy3VRLRcTlp5ADBbrBR0lq3SA1Rfw3MtM4TQu1xo3kxscfVdQ==", + "engines": { + "node": ">=12" } }, - "node_modules/domelementtype": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.2.0.tgz", - "integrity": "sha512-DtBMo82pv1dFtUmHyr48beiuq792Sxohr+8Hm9zoxklYPfa6n0Z3Byjj2IV7bmr2IyqClnqEQhfgHJJ5QF0R5A==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/fb55" + "node_modules/discord.js/node_modules/ws": { + "version": "8.2.3", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.2.3.tgz", + "integrity": "sha512-wBuoj1BDpC6ZQ1B7DWQBYVLphPWkm8i9Y0/3YdHjHKHiohOJ1ws+3OccDWtH+PoC9DZD5WOTrJvNbWvjS6JWaA==", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true } - ] + } }, - "node_modules/domhandler": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.2.2.tgz", - "integrity": "sha512-PzE9aBMsdZO8TK4BnuJwH0QT41wgMbRzuZrHUcpYncEjmQazq8QEaBWgLG7ZyC/DAZKEgglpIA6j4Qn/HmxS3w==", + "node_modules/distube": { + "version": "3.0.0-beta.39", + "resolved": "https://registry.npmjs.org/distube/-/distube-3.0.0-beta.39.tgz", + "integrity": "sha512-nbOJM3CZc5G5o+lBCd409NeiEQsEMglTLxCjoDsBbEm9ktaJ7sWcGZ2ofuflUSlNwuZyAgja6sWFVGvo3rQyhA==", "dependencies": { - "domelementtype": "^2.2.0" + "@distube/youtube-dl": "^2.2.2", + "@distube/ytdl-core": "^4.9.3", + "@distube/ytpl": "^1.0.12", + "@distube/ytsr": "^1.1.5", + "prism-media": "github:distubejs/prism-media", + "tiny-typed-emitter": "^2.1.0" }, "engines": { - "node": ">= 4" + "node": ">=12.0.0" }, "funding": { - "url": "https://github.com/fb55/domhandler?sponsor=1" + "url": "https://patreon.com/DisTube" + }, + "peerDependencies": { + "@discordjs/opus": "*", + "@discordjs/voice": ">=0.5.6", + "discord.js": "^12.5.0||^13.0.0-0||^13.1.0-0||^13.2.0-0" + } + }, + "node_modules/distube/node_modules/prism-media": { + "version": "1.3.2", + "resolved": "git+ssh://git@github.com/distubejs/prism-media.git#5317c4c6273669f6286d7f30c019307a1941c202", + "license": "Apache-2.0", + "peerDependencies": { + "@discordjs/opus": "*", + "ffmpeg-static": "^4.2.7 || ^3.0.0 || ^2.4.0", + "node-opus": "^0.3.3", + "opusscript": "^0.0.8" + }, + "peerDependenciesMeta": { + "@discordjs/opus": { + "optional": true + }, + "ffmpeg-static": { + "optional": true + }, + "node-opus": { + "optional": true + }, + "opusscript": { + "optional": true + } } }, - "node_modules/domutils": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", - "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "node_modules/doctrine": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", + "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", + "dev": true, "dependencies": { - "dom-serializer": "^1.0.1", - "domelementtype": "^2.2.0", - "domhandler": "^4.2.0" + "esutils": "^2.0.2" }, - "funding": { - "url": "https://github.com/fb55/domutils?sponsor=1" + "engines": { + "node": ">=6.0.0" } }, "node_modules/dot-prop": { @@ -1141,6 +1321,14 @@ "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "dev": true }, + "node_modules/end-of-stream": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", + "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "dependencies": { + "once": "^1.4.0" + } + }, "node_modules/enquirer": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.3.6.tgz", @@ -1153,14 +1341,6 @@ "node": ">=8.6" } }, - "node_modules/entities": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", - "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", - "funding": { - "url": "https://github.com/fb55/entities?sponsor=1" - } - }, "node_modules/env-paths": { "version": "2.2.1", "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", @@ -1380,6 +1560,28 @@ "node": ">=0.10.0" } }, + "node_modules/execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, "node_modules/fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -1414,6 +1616,11 @@ "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=", "dev": true }, + "node_modules/fast-safe-stringify": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/fast-safe-stringify/-/fast-safe-stringify-2.1.1.tgz", + "integrity": "sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA==" + }, "node_modules/fastq": { "version": "1.13.0", "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.13.0.tgz", @@ -1481,6 +1688,46 @@ "integrity": "sha512-JaTY/wtrcSyvXJl4IMFHPKyFur1sE9AUqc0QnhOaJ0CxHtAoIV8pYDzeEfAaNEtGkOfq4gr3LBFmdXW5mOQFnA==", "dev": true }, + "node_modules/follow-redirects": { + "version": "1.14.4", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.14.4.tgz", + "integrity": "sha512-zwGkiSXC1MUJG/qmeIFH2HBJx9u0V46QGUe3YR1fXG8bXQxq7fLj0RjLZQ5nubr9qNJUZrH+xUcwXEoXNpfS+g==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "engines": { + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } + } + }, + "node_modules/form-data": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-3.0.1.tgz", + "integrity": "sha512-RHkBKtLWUVwd7SqRIvCZMEvAMoGUp0XU+seQiZejj0COz3RI3hWP4sCv3gZWWLjJTd7rGwcsF5eKZGii0r/hbg==", + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/formidable": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/formidable/-/formidable-1.2.2.tgz", + "integrity": "sha512-V8gLm+41I/8kguQ4/o1D3RIHRmhYFG4pnNyonvua+40rqcEmT4+V71yaZ3B457xbbgCsCfjSPi65u/W6vK1U5Q==", + "funding": { + "url": "https://ko-fi.com/tunnckoCore/commissions" + } + }, "node_modules/fs-minipass": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", @@ -1497,6 +1744,11 @@ "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" }, + "node_modules/function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, "node_modules/functional-red-black-tree": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz", @@ -1561,6 +1813,30 @@ "node": ">=4" } }, + "node_modules/get-intrinsic": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz", + "integrity": "sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q==", + "dependencies": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/glob": { "version": "7.1.7", "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.7.tgz", @@ -1636,14 +1912,61 @@ "node": ">= 4" } }, + "node_modules/got": { + "version": "11.8.2", + "resolved": "https://registry.npmjs.org/got/-/got-11.8.2.tgz", + "integrity": "sha512-D0QywKgIe30ODs+fm8wMZiAcZjypcCodPNuMz5H9Mny7RJ+IjJ10BdmGW7OM7fHXP+O7r6ZwapQ/YQmMSvB0UQ==", + "dependencies": { + "@sindresorhus/is": "^4.0.0", + "@szmarczak/http-timer": "^4.0.5", + "@types/cacheable-request": "^6.0.1", + "@types/responselike": "^1.0.0", + "cacheable-lookup": "^5.0.3", + "cacheable-request": "^7.0.1", + "decompress-response": "^6.0.0", + "http2-wrapper": "^1.0.0-beta.5.2", + "lowercase-keys": "^2.0.0", + "p-cancelable": "^2.0.0", + "responselike": "^2.0.0" + }, + "engines": { + "node": ">=10.19.0" + }, + "funding": { + "url": "https://github.com/sindresorhus/got?sponsor=1" + } + }, + "node_modules/has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dependencies": { + "function-bind": "^1.1.1" + }, + "engines": { + "node": ">= 0.4.0" + } + }, "node_modules/has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, "engines": { "node": ">=8" } }, + "node_modules/has-symbols": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.2.tgz", + "integrity": "sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/has-unicode": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", @@ -1654,23 +1977,10 @@ "resolved": "https://registry.npmjs.org/himalaya/-/himalaya-1.1.0.tgz", "integrity": "sha512-LLase1dHCRMel68/HZTFft0N0wti0epHr3nNY7ynpLbyZpmrKMQ8YIpiOV77TM97cNpC8Wb2n6f66IRggwdWPw==" }, - "node_modules/htmlparser2": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-6.1.0.tgz", - "integrity": "sha512-gyyPk6rgonLFEDGoeRgQNaEUvdJ4ktTmmUh/h2t7s+M8oPpIPxgNACWa+6ESR57kXstwqPiCut0V8NRpcwgU7A==", - "funding": [ - "https://github.com/fb55/htmlparser2?sponsor=1", - { - "type": "github", - "url": "https://github.com/sponsors/fb55" - } - ], - "dependencies": { - "domelementtype": "^2.0.1", - "domhandler": "^4.0.0", - "domutils": "^2.5.2", - "entities": "^2.0.0" - } + "node_modules/http-cache-semantics": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.0.tgz", + "integrity": "sha512-carPklcUh7ROWRK7Cv27RPtdhYhUsela/ue5/jKzjegVvXDqM2ILE9Q2BGn9JZJh1g87cp56su/FgQSzcWS8cQ==" }, "node_modules/http-response-object": { "version": "3.0.2", @@ -1685,6 +1995,18 @@ "resolved": "https://registry.npmjs.org/@types/node/-/node-10.17.60.tgz", "integrity": "sha512-F0KIgDJfy2nA3zMLmWGKxcH2ZVEtCZXHHdOQs2gSaQ27+lNeEfGxzkIw90aXswATX7AZ33tahPbzy6KAfUreVw==" }, + "node_modules/http2-wrapper": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/http2-wrapper/-/http2-wrapper-1.0.3.tgz", + "integrity": "sha512-V+23sDMr12Wnz7iTcDeJr3O6AIxlnvT/bmaAAAP/Xda35C90p9599p0F1eHR/N1KILWSoWVAiOMFjBBXaXSMxg==", + "dependencies": { + "quick-lru": "^5.1.1", + "resolve-alpn": "^1.0.0" + }, + "engines": { + "node": ">=10.19.0" + } + }, "node_modules/https-proxy-agent": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.0.tgz", @@ -1697,6 +2019,14 @@ "node": ">= 6" } }, + "node_modules/human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "engines": { + "node": ">=10.17.0" + } + }, "node_modules/ignore": { "version": "4.0.6", "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz", @@ -1784,12 +2114,31 @@ "node": ">=0.12.0" } }, - "node_modules/is-obj": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-obj/-/is-obj-2.0.0.tgz", - "integrity": "sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w==", + "node_modules/is-obj": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-obj/-/is-obj-2.0.0.tgz", + "integrity": "sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w==", + "engines": { + "node": ">=8" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-unix": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-unix/-/is-unix-1.0.1.tgz", + "integrity": "sha512-8Iu9y/xCBmg1uwWV3J/jNl3udPHPAYyqGv4OKE/70O10U2qmt1v3/SRhSAW5+GiRpU2yZEnl+z1Oxm4A8arVrA==", "engines": { - "node": ">=8" + "node": ">= 12" } }, "node_modules/isarray": { @@ -1800,8 +2149,7 @@ "node_modules/isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", - "dev": true + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" }, "node_modules/js-tokens": { "version": "4.0.0", @@ -1822,6 +2170,11 @@ "js-yaml": "bin/js-yaml.js" } }, + "node_modules/json-buffer": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", + "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==" + }, "node_modules/json-schema-traverse": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", @@ -1834,6 +2187,14 @@ "integrity": "sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=", "dev": true }, + "node_modules/keyv": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.0.3.tgz", + "integrity": "sha512-zdGa2TOpSZPq5mU6iowDARnMBZgtCqJ11dJROFi6tg6kTn4nuUdU09lFyLFSaHrWqpIJ+EBq4E8/Dc0Vx5vLdA==", + "dependencies": { + "json-buffer": "3.0.1" + } + }, "node_modules/levn": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", @@ -1883,6 +2244,14 @@ "integrity": "sha1-WjUNoLERO4N+z//VgSy+WNbq4ZM=", "dev": true }, + "node_modules/lowercase-keys": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-2.0.0.tgz", + "integrity": "sha512-tqNXrS78oMOE73NMxK4EMLQsQowWf8jKooH9g7xPavRT706R6bkQJ6DY2Te7QukaZsulxa30wQ7bk0pm4XiHmA==", + "engines": { + "node": ">=8" + } + }, "node_modules/lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -1928,6 +2297,11 @@ "semver": "bin/semver.js" } }, + "node_modules/merge-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==" + }, "node_modules/merge2": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", @@ -1937,6 +2311,14 @@ "node": ">= 8" } }, + "node_modules/methods": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", + "integrity": "sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4=", + "engines": { + "node": ">= 0.6" + } + }, "node_modules/micromatch": { "version": "4.0.4", "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.4.tgz", @@ -1950,25 +2332,52 @@ "node": ">=8.6" } }, + "node_modules/mime": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/mime/-/mime-2.5.2.tgz", + "integrity": "sha512-tqkh47FzKeCPD2PUiPB6pkbMzsCasjxAfC62/Wap5qrUWcb+sFasXUC5I3gYM5iBM8v/Qpn4UK0x+j0iHyFPDg==", + "bin": { + "mime": "cli.js" + }, + "engines": { + "node": ">=4.0.0" + } + }, "node_modules/mime-db": { - "version": "1.49.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.49.0.tgz", - "integrity": "sha512-CIc8j9URtOVApSFCQIF+VBkX1RwXp/oMMOrqdyXSBXq5RWNEsRfyj1kiRnQgmNXmHxPoFIxOroKA3zcU9P+nAA==", + "version": "1.50.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.50.0.tgz", + "integrity": "sha512-9tMZCDlYHqeERXEHO9f/hKfNXhre5dK2eE/krIvUjZbS2KPcqGDfNShIWS1uW9XOTKQKqK6qbeOci18rbfW77A==", "engines": { "node": ">= 0.6" } }, "node_modules/mime-types": { - "version": "2.1.32", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.32.tgz", - "integrity": "sha512-hJGaVS4G4c9TSMYh2n6SQAGrC4RnfU+daP8G7cSCmaqNjiOoUY0VHCMS42pxnQmVF1GWwFhbHWn3RIxCqTmZ9A==", + "version": "2.1.33", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.33.tgz", + "integrity": "sha512-plLElXp7pRDd0bNZHw+nMd52vRYjLwQjygaNg7ddJ2uJtTlmnTCjWuPKxVu6//AdaRuME84SvLW91sIkBqGT0g==", "dependencies": { - "mime-db": "1.49.0" + "mime-db": "1.50.0" }, "engines": { "node": ">= 0.6" } }, + "node_modules/mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "engines": { + "node": ">=6" + } + }, + "node_modules/mimic-response": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-1.0.1.tgz", + "integrity": "sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ==", + "engines": { + "node": ">=4" + } + }, "node_modules/miniget": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/miniget/-/miniget-4.2.1.tgz", @@ -2011,6 +2420,17 @@ "node": ">= 8" } }, + "node_modules/mkdirp": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", + "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", + "bin": { + "mkdirp": "bin/cmd.js" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/ms": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", @@ -2023,9 +2443,9 @@ "dev": true }, "node_modules/node-addon-api": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-4.1.0.tgz", - "integrity": "sha512-Zz1o1BDX2VtduiAt6kgiUl8jX1Vm3NMboljFYKQJ6ee8AGfiTvM2mlZFI3xPbqjs80rCQgiVJI/DjQ/1QJ0HwA==" + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-3.2.1.tgz", + "integrity": "sha512-mmcei9JghVNDYydghQmeDX8KoAm0FAiYyIcUt/N4nhyAipB17pllZQDOJD2fotxABnt4Mdz+dKTO7eftLg4d0A==" }, "node_modules/node-fetch": { "version": "2.6.2", @@ -2049,6 +2469,28 @@ "node": ">=6" } }, + "node_modules/normalize-url": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-6.1.0.tgz", + "integrity": "sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A==", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/npm-run-path": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", + "dependencies": { + "path-key": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/npmlog": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-5.0.1.tgz", @@ -2060,17 +2502,6 @@ "set-blocking": "^2.0.0" } }, - "node_modules/nth-check": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.0.1.tgz", - "integrity": "sha512-it1vE95zF6dTT9lBsYbxvqh0Soy4SPowchj0UBGj/V6cTPnXXtQOPUbhZ6CmGzAD/rW22LQK6E96pcdJXk4A4w==", - "dependencies": { - "boolbase": "^1.0.0" - }, - "funding": { - "url": "https://github.com/fb55/nth-check?sponsor=1" - } - }, "node_modules/object-assign": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", @@ -2079,6 +2510,14 @@ "node": ">=0.10.0" } }, + "node_modules/object-inspect": { + "version": "1.11.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.11.0.tgz", + "integrity": "sha512-jp7ikS6Sd3GxQfZJPyH3cjcbJF6GZPClgdV+EFygjFLQ5FmW/dRUnTd9PQ9k0JhoNDabWFbpF1yCdSWCC6gexg==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -2087,6 +2526,20 @@ "wrappy": "1" } }, + "node_modules/onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "dependencies": { + "mimic-fn": "^2.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/optionator": { "version": "0.9.1", "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.1.tgz", @@ -2134,6 +2587,55 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/p-cancelable": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/p-cancelable/-/p-cancelable-2.1.1.tgz", + "integrity": "sha512-BZOr3nRQHOntUjTrH8+Lh54smKHoHyur8We1V8DSMVrl5A2malOOwuJRnKRDjSnkoeBh4at6BwEnb5I7Jl31wg==", + "engines": { + "node": ">=8" + } + }, + "node_modules/p-event": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/p-event/-/p-event-4.2.0.tgz", + "integrity": "sha512-KXatOjCRXXkSePPb1Nbi0p0m+gQAwdlbhi4wQKJPI1HsMQS9g+Sqp2o+QHziPr7eYJyOZet836KoHEVM1mwOrQ==", + "dependencies": { + "p-timeout": "^3.1.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-finally": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", + "integrity": "sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4=", + "engines": { + "node": ">=4" + } + }, + "node_modules/p-reflect": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/p-reflect/-/p-reflect-2.1.0.tgz", + "integrity": "sha512-paHV8NUz8zDHu5lhr/ngGWQiW067DK/+IbJ+RfZ4k+s8y4EKyYCz8pGYWjxCg35eHztpJAt+NUgvN4L+GCbPlg==", + "engines": { + "node": ">=8" + } + }, + "node_modules/p-timeout": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/p-timeout/-/p-timeout-3.2.0.tgz", + "integrity": "sha512-rhIwUycgwwKcP9yTOOFK/AKsAopjjCakVqLHePO3CC6Mir1Z99xT+R63jZxAT5lFZLa2inS5h+ZS2GvR99/FBg==", + "dependencies": { + "p-finally": "^1.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/parent-module": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", @@ -2151,19 +2653,6 @@ "resolved": "https://registry.npmjs.org/parse-cache-control/-/parse-cache-control-1.0.1.tgz", "integrity": "sha1-juqz5U+laSD+Fro493+iGqzC104=" }, - "node_modules/parse5": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/parse5/-/parse5-6.0.1.tgz", - "integrity": "sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw==" - }, - "node_modules/parse5-htmlparser2-tree-adapter": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-6.0.1.tgz", - "integrity": "sha512-qPuWvbLgvDGilKc5BoicRovlT4MtYT6JfJyBOMDsKoiT+GiuP5qyrPCnR9HcPECIJJmZh5jRndyNThnhhb/vlA==", - "dependencies": { - "parse5": "^6.0.1" - } - }, "node_modules/path-is-absolute": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", @@ -2176,7 +2665,6 @@ "version": "3.1.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", - "dev": true, "engines": { "node": ">=8" } @@ -2249,6 +2737,15 @@ "node": ">=0.4.0" } }, + "node_modules/pump": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", + "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, "node_modules/punycode": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", @@ -2258,6 +2755,20 @@ "node": ">=6" } }, + "node_modules/qs": { + "version": "6.10.1", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.10.1.tgz", + "integrity": "sha512-M528Hph6wsSVOBiYUnGf+K/7w0hNshs/duGsNXPUCLH5XAqjEtiPGwNONLV0tBH8NoGb0mvD5JubnUTrujKDTg==", + "dependencies": { + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -2278,6 +2789,17 @@ } ] }, + "node_modules/quick-lru": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-5.1.1.tgz", + "integrity": "sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/readable-stream": { "version": "2.3.7", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", @@ -2313,6 +2835,11 @@ "node": ">=0.10.0" } }, + "node_modules/resolve-alpn": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/resolve-alpn/-/resolve-alpn-1.2.1.tgz", + "integrity": "sha512-0a1F4l73/ZFZOakJnQ3FvkJ2+gSTQWz/r2KE5OdDY0TxPm5h4GkqkWWfM47T7HsbnOtcJVEF4epCVy6u7Q3K+g==" + }, "node_modules/resolve-from": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", @@ -2322,6 +2849,14 @@ "node": ">=4" } }, + "node_modules/responselike": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/responselike/-/responselike-2.0.0.tgz", + "integrity": "sha512-xH48u3FTB9VsZw7R+vvgaKeLKzT6jOogbQhEe/jewwnZgzPcnyWui2Av6JpoYZF/91uueC+lqhWqeURw5/qhCw==", + "dependencies": { + "lowercase-keys": "^2.0.0" + } + }, "node_modules/reusify": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", @@ -2402,7 +2937,6 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", - "dev": true, "dependencies": { "shebang-regex": "^3.0.0" }, @@ -2414,11 +2948,23 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", - "dev": true, "engines": { "node": ">=8" } }, + "node_modules/side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "dependencies": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/signal-exit": { "version": "3.0.3", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.3.tgz", @@ -2450,14 +2996,12 @@ "url": "https://github.com/chalk/slice-ansi?sponsor=1" } }, - "node_modules/soundcloud-scraper": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/soundcloud-scraper/-/soundcloud-scraper-5.0.2.tgz", - "integrity": "sha512-QAPvRIG4eefc7JdmCQCG/QEhm4D90XgHbe9lJMHmKIxU0INdAD2LycUR1m0mCIKF3F2dk4NvGEkxGfVLI8Af+A==", + "node_modules/soundcloud.ts": { + "version": "0.4.5", + "resolved": "https://registry.npmjs.org/soundcloud.ts/-/soundcloud.ts-0.4.5.tgz", + "integrity": "sha512-WAQN687lCs7ig4xciXaNSX3iZ5+XWM5l00jQx3edVsw8ySjPyIymHuSKeHZJBrpKCZbPnnvzEWaBYDK7+eYDCw==", "dependencies": { - "cheerio": "^1.0.0-rc.10", - "m3u8stream": "^0.8.4", - "node-fetch": "^2.6.1" + "axios": "^0.21.1" } }, "node_modules/spotify-uri": { @@ -2481,6 +3025,14 @@ "node": ">= 12" } }, + "node_modules/spotify-web-api-node": { + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/spotify-web-api-node/-/spotify-web-api-node-5.0.2.tgz", + "integrity": "sha512-r82dRWU9PMimHvHEzL0DwEJrzFk+SMCVfq249SLt3I7EFez7R+jeoKQd+M1//QcnjqlXPs2am4DFsGk8/GCsrA==", + "dependencies": { + "superagent": "^6.1.0" + } + }, "node_modules/sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", @@ -2521,6 +3073,14 @@ "node": ">=8" } }, + "node_modules/strip-final-newline": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", + "engines": { + "node": ">=6" + } + }, "node_modules/strip-json-comments": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", @@ -2533,10 +3093,45 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/superagent": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/superagent/-/superagent-6.1.0.tgz", + "integrity": "sha512-OUDHEssirmplo3F+1HWKUrUjvnQuA+nZI6i/JJBdXb5eq9IyEQwPyPpqND+SSsxf6TygpBEkUjISVRN4/VOpeg==", + "dependencies": { + "component-emitter": "^1.3.0", + "cookiejar": "^2.1.2", + "debug": "^4.1.1", + "fast-safe-stringify": "^2.0.7", + "form-data": "^3.0.0", + "formidable": "^1.2.2", + "methods": "^1.1.2", + "mime": "^2.4.6", + "qs": "^6.9.4", + "readable-stream": "^3.6.0", + "semver": "^7.3.2" + }, + "engines": { + "node": ">= 7.0.0" + } + }, + "node_modules/superagent/node_modules/readable-stream": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.0.tgz", + "integrity": "sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA==", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, "node_modules/supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, "dependencies": { "has-flag": "^4.0.0" }, @@ -2599,17 +3194,6 @@ "node": ">= 10" } }, - "node_modules/tar/node_modules/mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "bin": { - "mkdirp": "bin/cmd.js" - }, - "engines": { - "node": ">=10" - } - }, "node_modules/text-table": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", @@ -2717,7 +3301,6 @@ "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "dev": true, "dependencies": { "isexe": "^2.0.0" }, @@ -2813,27 +3396,6 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" - }, - "node_modules/youtube-sr": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/youtube-sr/-/youtube-sr-4.1.7.tgz", - "integrity": "sha512-OKbm+561Fq5RlnUtJBmPhnyfS6Zon44zdPhY1v/Y9vpAHzqdfxomD43yc0ZQv6zNsVzSlAkGeWhoweNd6DUUjQ==", - "dependencies": { - "node-fetch": "^2.6.1" - } - }, - "node_modules/ytdl-core": { - "version": "4.9.1", - "resolved": "https://registry.npmjs.org/ytdl-core/-/ytdl-core-4.9.1.tgz", - "integrity": "sha512-6Jbp5RDhUEozlaJQAR+l8oV8AHsx3WUXxSyPxzE6wOIAaLql7Hjiy0ZM58wZoyj1YEenlEPjEqcJIjKYKxvHtQ==", - "dependencies": { - "m3u8stream": "^0.8.3", - "miniget": "^4.0.0", - "sax": "^1.1.3" - }, - "engines": { - "node": ">=10" - } } }, "dependencies": { @@ -2933,15 +3495,15 @@ } }, "@discordjs/builders": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/@discordjs/builders/-/builders-0.5.0.tgz", - "integrity": "sha512-HP5y4Rqw68o61Qv4qM5tVmDbWi4mdTFftqIOGRo33SNPpLJ1Ga3KEIR2ibKofkmsoQhEpLmopD1AZDs3cKpHuw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/@discordjs/builders/-/builders-0.6.0.tgz", + "integrity": "sha512-mH3Gx61LKk2CD05laCI9K5wp+a3NyASHDUGx83DGJFkqJlRlSV5WMJNY6RS37A5SjqDtGMF4wVR9jzFaqShe6Q==", "requires": { "@sindresorhus/is": "^4.0.1", "discord-api-types": "^0.22.0", "ow": "^0.27.0", "ts-mixer": "^6.0.0", - "tslib": "^2.3.0" + "tslib": "^2.3.1" } }, "@discordjs/collection": { @@ -2976,12 +3538,12 @@ } }, "@discordjs/opus": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/@discordjs/opus/-/opus-0.6.0.tgz", - "integrity": "sha512-Xuw8OP9BJgObEBs/SgxixnKj+y+w9st45uOAJ+cGegUGwxAIR4J7sQt3Y1J3G9SGGe82+MTxvy7sg1/QUkigcg==", + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/@discordjs/opus/-/opus-0.5.3.tgz", + "integrity": "sha512-IQhCwCy2WKXLe+qkOkwO1Wjgk20uqeAbqM62tCbzIqbTsXX4YAge8Me9RFnI77Lx+UTkgm4rSVM3VPVdS/GsUw==", "requires": { - "@discordjs/node-pre-gyp": "^0.4.1", - "node-addon-api": "^4.0.0" + "@discordjs/node-pre-gyp": "^0.4.0", + "node-addon-api": "^3.2.1" } }, "@discordjs/voice": { @@ -2996,6 +3558,65 @@ "ws": "^7.4.4" } }, + "@distube/soundcloud": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/@distube/soundcloud/-/soundcloud-0.2.2.tgz", + "integrity": "sha512-N5bBP+KmJ3QmcZBn/LPnk+oMl5AIOwSvB5rfyuKhKn6sRaxMdI0VmyKgAbnZz17vS3LLRAKAr4BFYleflTpRhA==", + "requires": { + "soundcloud.ts": "^0.4.1" + } + }, + "@distube/spotify": { + "version": "0.6.4", + "resolved": "https://registry.npmjs.org/@distube/spotify/-/spotify-0.6.4.tgz", + "integrity": "sha512-MhmhLmWv9ipBJhRvQ6S1wtWL5cOuWhl89NBGcoc4AlvHOgnydVOuY7+DKOua+JSyiDXlI6qRPeyLQNfx/AtgRg==", + "requires": { + "spotify-uri": "^2.2.0", + "spotify-url-info": "^2.2.3", + "spotify-web-api-node": "^5.0.2" + } + }, + "@distube/youtube-dl": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/@distube/youtube-dl/-/youtube-dl-2.2.2.tgz", + "integrity": "sha512-r/+nt1Cvx6OIp0xI2NqtUMpVfavlmRN/7J379h7At6XAzfNMYn8dQcZZcgH0ErNE19rvFefQ0b0mGj/vwzp0kA==", + "requires": { + "dargs": "~7.0.0", + "execa": "~5.1.1", + "get-stream": "~6.0.1", + "got": "~11.8.2", + "is-unix": "~1.0.0", + "mkdirp": "~1.0.4", + "p-event": "~4.2.0", + "p-reflect": "~2.1.0" + } + }, + "@distube/ytdl-core": { + "version": "4.9.3", + "resolved": "https://registry.npmjs.org/@distube/ytdl-core/-/ytdl-core-4.9.3.tgz", + "integrity": "sha512-oj/XoIvY2Vc7eySHvbschqPNU4gFNkF9s5er1eljGzcBC5TP+ygt/TAo59yOJEZJe5gTsaIvbv/4W6IKCuBUPg==", + "requires": { + "m3u8stream": "^0.8.3", + "miniget": "^4.0.0", + "sax": "^1.1.3" + } + }, + "@distube/ytpl": { + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/@distube/ytpl/-/ytpl-1.0.12.tgz", + "integrity": "sha512-Iv6qZpUkyL+R2KQhfuvmYnqlMX+n8ts44aZ3hZUJI2dAV7lCZdsRs5MAf7oOSfZrTLL4GMNex8RGmBarm7iHtg==", + "requires": { + "miniget": "^4.2.1" + } + }, + "@distube/ytsr": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/@distube/ytsr/-/ytsr-1.1.5.tgz", + "integrity": "sha512-nSYsB+UYw0FXSivJ49MGkES41Gfg5rgavil9nOHra0yCsGiY4qsDzpoFVjCmbpKQ6GDUq4Z/8LOwZakgpH3N1A==", + "requires": { + "miniget": "^4.2.1" + } + }, "@eslint/eslintrc": { "version": "0.4.3", "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-0.4.3.tgz", @@ -3057,14 +3678,38 @@ } }, "@sapphire/async-queue": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/@sapphire/async-queue/-/async-queue-1.1.4.tgz", - "integrity": "sha512-fFrlF/uWpGOX5djw5Mu2Hnnrunao75WGey0sP0J3jnhmrJ5TAPzHYOmytD5iN/+pMxS+f+u/gezqHa9tPhRHEA==" + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/@sapphire/async-queue/-/async-queue-1.1.6.tgz", + "integrity": "sha512-M5CbgMgesemMUCQo5G/InGHvp+GZx6uuJNV1iwvSWD8EFNVrfxaTcqhcAXM3MPYkjlxvNnoDNk0R1lfzvca6LA==" }, "@sindresorhus/is": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.1.0.tgz", - "integrity": "sha512-Cgva8HxclecUCmAImsWsbZGUh6p5DSzQ8l2Uzxuj9ANiD7LVhLM1UJ2hX/R2Y+ILpvqgW9QjmTCaBkXtj8+UOg==" + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.2.0.tgz", + "integrity": "sha512-VkE3KLBmJwcCaVARtQpfuKcKv8gcBmUubrfHGF84dXuuW6jgsRYxPtzcIhPyK9WAPpRt2/xY6zkD9MnRaJzSyw==" + }, + "@szmarczak/http-timer": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/@szmarczak/http-timer/-/http-timer-4.0.6.tgz", + "integrity": "sha512-4BAffykYOgO+5nzBWYwE3W90sBgLJoUPRWWcL8wlyiM8IB8ipJz3UMJ9KXQd1RKQXpKp8Tutn80HZtWsu2u76w==", + "requires": { + "defer-to-connect": "^2.0.0" + } + }, + "@types/cacheable-request": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/@types/cacheable-request/-/cacheable-request-6.0.2.tgz", + "integrity": "sha512-B3xVo+dlKM6nnKTcmm5ZtY/OL8bOAOd2Olee9M1zft65ox50OzjEHW91sDiU9j6cvW8Ejg1/Qkf4xd2kugApUA==", + "requires": { + "@types/http-cache-semantics": "*", + "@types/keyv": "*", + "@types/node": "*", + "@types/responselike": "*" + } + }, + "@types/http-cache-semantics": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@types/http-cache-semantics/-/http-cache-semantics-4.0.1.tgz", + "integrity": "sha512-SZs7ekbP8CN0txVG2xVRH6EgKmEm31BOxA07vkFaETzZz1xh+cbt8BcI0slpymvwhx5dlFnQG2rTlPVQn+iRPQ==" }, "@types/json-schema": { "version": "7.0.9", @@ -3072,10 +3717,26 @@ "integrity": "sha512-qcUXuemtEu+E5wZSJHNxUXeCZhAfXKQ41D+duX+VYPde7xyEVZci+/oXKJL13tnRs9lR2pr4fod59GT6/X1/yQ==", "dev": true }, + "@types/keyv": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@types/keyv/-/keyv-3.1.3.tgz", + "integrity": "sha512-FXCJgyyN3ivVgRoml4h94G/p3kY+u/B86La+QptcqJaWtBWtmc6TtkNfS40n9bIvyLteHh7zXOtgbobORKPbDg==", + "requires": { + "@types/node": "*" + } + }, "@types/node": { - "version": "16.9.1", - "resolved": "https://registry.npmjs.org/@types/node/-/node-16.9.1.tgz", - "integrity": "sha512-QpLcX9ZSsq3YYUUnD3nFDY8H7wctAhQj/TFKL8Ya8v5fMm3CFXxo8zStsLAl780ltoYoo1WvKUVGBQK+1ifr7g==" + "version": "16.10.4", + "resolved": "https://registry.npmjs.org/@types/node/-/node-16.10.4.tgz", + "integrity": "sha512-EITwVTX5B4nDjXjGeQAfXOrm+Jn+qNjDmyDRtWoD+wZsl/RDPRTFRKivs4Mt74iOFlLOrE5+Kf+p5yjyhm3+cA==" + }, + "@types/responselike": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@types/responselike/-/responselike-1.0.0.tgz", + "integrity": "sha512-85Y2BjiufFzaMIlvJDvTTB8Fxl2xfLo4HgmHzVBz08w4wDePCTjYw66PdrolO0kzli3yam/YCgRufyo1DdQVTA==", + "requires": { + "@types/node": "*" + } }, "@types/ws": { "version": "7.4.7", @@ -3266,6 +3927,7 @@ "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, "requires": { "color-convert": "^2.0.1" } @@ -3322,16 +3984,19 @@ "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=" }, + "axios": { + "version": "0.21.4", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.21.4.tgz", + "integrity": "sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg==", + "requires": { + "follow-redirects": "^1.14.0" + } + }, "balanced-match": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" }, - "boolbase": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", - "integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24=" - }, "brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -3355,6 +4020,44 @@ "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" }, + "cacheable-lookup": { + "version": "5.0.4", + "resolved": "https://registry.npmjs.org/cacheable-lookup/-/cacheable-lookup-5.0.4.tgz", + "integrity": "sha512-2/kNscPhpcxrOigMZzbiWF7dz8ilhb/nIHU3EyZiXWXpeq/au8qJ8VhdftMkty3n7Gj6HIGalQG8oiBNB3AJgA==" + }, + "cacheable-request": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/cacheable-request/-/cacheable-request-7.0.2.tgz", + "integrity": "sha512-pouW8/FmiPQbuGpkXQ9BAPv/Mo5xDGANgSNXzTzJ8DrKGuXOssM4wIQRjfanNRh3Yu5cfYPvcorqbhg2KIJtew==", + "requires": { + "clone-response": "^1.0.2", + "get-stream": "^5.1.0", + "http-cache-semantics": "^4.0.0", + "keyv": "^4.0.0", + "lowercase-keys": "^2.0.0", + "normalize-url": "^6.0.1", + "responselike": "^2.0.0" + }, + "dependencies": { + "get-stream": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", + "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", + "requires": { + "pump": "^3.0.0" + } + } + } + }, + "call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "requires": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + } + }, "callsites": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", @@ -3369,46 +4072,30 @@ "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, "requires": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" } }, - "cheerio": { - "version": "1.0.0-rc.10", - "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.0.0-rc.10.tgz", - "integrity": "sha512-g0J0q/O6mW8z5zxQ3A8E8J1hUgp4SMOvEoW/x84OwyHKe/Zccz83PVT4y5Crcr530FV6NgmKI1qvGTKVl9XXVw==", - "requires": { - "cheerio-select": "^1.5.0", - "dom-serializer": "^1.3.2", - "domhandler": "^4.2.0", - "htmlparser2": "^6.1.0", - "parse5": "^6.0.1", - "parse5-htmlparser2-tree-adapter": "^6.0.1", - "tslib": "^2.2.0" - } - }, - "cheerio-select": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/cheerio-select/-/cheerio-select-1.5.0.tgz", - "integrity": "sha512-qocaHPv5ypefh6YNxvnbABM07KMxExbtbfuJoIie3iZXX1ERwYmJcIiRrr9H05ucQP1k28dav8rpdDgjQd8drg==", - "requires": { - "css-select": "^4.1.3", - "css-what": "^5.0.1", - "domelementtype": "^2.2.0", - "domhandler": "^4.2.0", - "domutils": "^2.7.0" - } - }, "chownr": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz", "integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==" }, + "clone-response": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/clone-response/-/clone-response-1.0.2.tgz", + "integrity": "sha1-0dyXOSAxTfZ/vrlCI7TuNQI56Ws=", + "requires": { + "mimic-response": "^1.0.0" + } + }, "color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, "requires": { "color-name": "~1.1.4" } @@ -3416,7 +4103,8 @@ "color-name": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true }, "color-support": { "version": "1.1.3", @@ -3431,6 +4119,11 @@ "delayed-stream": "~1.0.0" } }, + "component-emitter": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.3.0.tgz", + "integrity": "sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg==" + }, "concat-map": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", @@ -3452,6 +4145,11 @@ "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=" }, + "cookiejar": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/cookiejar/-/cookiejar-2.1.3.tgz", + "integrity": "sha512-JxbCBUdrfr6AQjOXrxoTvAMJO4HBTUIlBzslcJPAz+/KT8yk53fXun51u+RenNYvad/+Vc2DIz5o9UxlCDymFQ==" + }, "core-util-is": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", @@ -3476,29 +4174,16 @@ "version": "7.0.3", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", - "dev": true, "requires": { "path-key": "^3.1.0", "shebang-command": "^2.0.0", "which": "^2.0.1" } }, - "css-select": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.1.3.tgz", - "integrity": "sha512-gT3wBNd9Nj49rAbmtFHj1cljIAOLYSX1nZ8CB7TBO3INYckygm5B7LISU/szY//YmdiSLbJvDLOx9VnMVpMBxA==", - "requires": { - "boolbase": "^1.0.0", - "css-what": "^5.0.0", - "domhandler": "^4.2.0", - "domutils": "^2.6.0", - "nth-check": "^2.0.0" - } - }, - "css-what": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/css-what/-/css-what-5.0.1.tgz", - "integrity": "sha512-FYDTSHb/7KXsWICVsxdmiExPjCfRC4qRFBdVwv7Ax9hMnvMmEjP9RfxTEZ3qPZGmADDn2vAKSo9UcN1jKVYscg==" + "dargs": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/dargs/-/dargs-7.0.0.tgz", + "integrity": "sha512-2iy1EkLdlBzQGvbweYRFxmFath8+K7+AKB0TlhHWkNuH+TmovaMH/Wp7V7R4u7f4SnX3OgLsU9t1NI9ioDnUpg==" }, "debug": { "version": "4.3.2", @@ -3508,12 +4193,32 @@ "ms": "2.1.2" } }, + "decompress-response": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", + "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", + "requires": { + "mimic-response": "^3.1.0" + }, + "dependencies": { + "mimic-response": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", + "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==" + } + } + }, "deep-is": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", "dev": true }, + "defer-to-connect": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/defer-to-connect/-/defer-to-connect-2.0.1.tgz", + "integrity": "sha512-4tvttepXG1VaYGrRibk5EwJd1t4udunSOVMdLSAL6mId1ix438oPwPZMALY41FCijukO1L0twNcGsdzS7dHgDg==" + }, "delayed-stream": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", @@ -3543,42 +4248,60 @@ "resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.22.0.tgz", "integrity": "sha512-l8yD/2zRbZItUQpy7ZxBJwaLX/Bs2TGaCthRppk8Sw24LOIWg12t9JEreezPoYD0SQcC2htNNo27kYEpYW/Srg==" }, - "discord-player": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/discord-player/-/discord-player-5.1.0.tgz", - "integrity": "sha512-Rp+A/k8sm3h+MfTxhdGZjFsEK26lf5YcyBhiLgEGvh/aRRxw7z9+twnIyEPHQC8gtTiZHlfHD7ihztKFT/XJCQ==", - "requires": { - "@discordjs/voice": "^0.6.0", - "discord-ytdl-core": "^5.0.4", - "libsodium-wrappers": "^0.7.9", - "soundcloud-scraper": "^5.0.2", - "spotify-url-info": "^2.2.3", - "tiny-typed-emitter": "^2.1.0", - "youtube-sr": "^4.1.7", - "ytdl-core": "^4.9.1" - } - }, - "discord-ytdl-core": { - "version": "5.0.4", - "resolved": "https://registry.npmjs.org/discord-ytdl-core/-/discord-ytdl-core-5.0.4.tgz", - "integrity": "sha512-O+G9wuCw5TERR9iHZFMYnYQbs/ZGudDc9cxa1OKSV5TdcBYrHGS1JqvE90ZvSQ6SmS4XvqtOf/Okls6yiGJ3sg==", - "requires": { - "prism-media": "^1.2.9" - } - }, "discord.js": { - "version": "13.1.0", - "resolved": "https://registry.npmjs.org/discord.js/-/discord.js-13.1.0.tgz", - "integrity": "sha512-gxO4CXKdHpqA+WKG+f5RNnd3srTDj5uFJHgOathksDE90YNq/Qijkd2WlMgTTMS6AJoEnHxI7G9eDQHCuZ+xDA==", + "version": "13.2.0", + "resolved": "https://registry.npmjs.org/discord.js/-/discord.js-13.2.0.tgz", + "integrity": "sha512-nyxUvL8wuQG38zx13wUMkpcA8koFszyiXdkSLwwM9opKW2LC2H5gD0cTZxImeJ6GtEnKPWT8xBiE8lLBmbNIhw==", "requires": { - "@discordjs/builders": "^0.5.0", + "@discordjs/builders": "^0.6.0", "@discordjs/collection": "^0.2.1", "@discordjs/form-data": "^3.0.1", - "@sapphire/async-queue": "^1.1.4", - "@types/ws": "^7.4.7", - "discord-api-types": "^0.22.0", + "@sapphire/async-queue": "^1.1.5", + "@types/ws": "^8.2.0", + "discord-api-types": "^0.23.1", "node-fetch": "^2.6.1", - "ws": "^7.5.1" + "ws": "^8.2.3" + }, + "dependencies": { + "@types/ws": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.2.0.tgz", + "integrity": "sha512-cyeefcUCgJlEk+hk2h3N+MqKKsPViQgF5boi9TTHSK+PoR9KWBb/C5ccPcDyAqgsbAYHTwulch725DV84+pSpg==", + "requires": { + "@types/node": "*" + } + }, + "discord-api-types": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.23.1.tgz", + "integrity": "sha512-igWmn+45mzXRWNEPU25I/pr8MwxHb767wAr51oy3VRLRcTlp5ADBbrBR0lq3SA1Rfw3MtM4TQu1xo3kxscfVdQ==" + }, + "ws": { + "version": "8.2.3", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.2.3.tgz", + "integrity": "sha512-wBuoj1BDpC6ZQ1B7DWQBYVLphPWkm8i9Y0/3YdHjHKHiohOJ1ws+3OccDWtH+PoC9DZD5WOTrJvNbWvjS6JWaA==", + "requires": {} + } + } + }, + "distube": { + "version": "3.0.0-beta.39", + "resolved": "https://registry.npmjs.org/distube/-/distube-3.0.0-beta.39.tgz", + "integrity": "sha512-nbOJM3CZc5G5o+lBCd409NeiEQsEMglTLxCjoDsBbEm9ktaJ7sWcGZ2ofuflUSlNwuZyAgja6sWFVGvo3rQyhA==", + "requires": { + "@distube/youtube-dl": "^2.2.2", + "@distube/ytdl-core": "^4.9.3", + "@distube/ytpl": "^1.0.12", + "@distube/ytsr": "^1.1.5", + "prism-media": "github:distubejs/prism-media", + "tiny-typed-emitter": "^2.1.0" + }, + "dependencies": { + "prism-media": { + "version": "git+ssh://git@github.com/distubejs/prism-media.git#5317c4c6273669f6286d7f30c019307a1941c202", + "from": "prism-media@github:distubejs/prism-media", + "requires": {} + } } }, "doctrine": { @@ -3590,39 +4313,6 @@ "esutils": "^2.0.2" } }, - "dom-serializer": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.3.2.tgz", - "integrity": "sha512-5c54Bk5Dw4qAxNOI1pFEizPSjVsx5+bpJKmL2kPn8JhBUq2q09tTCa3mjijun2NfK78NMouDYNMBkOrPZiS+ig==", - "requires": { - "domelementtype": "^2.0.1", - "domhandler": "^4.2.0", - "entities": "^2.0.0" - } - }, - "domelementtype": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.2.0.tgz", - "integrity": "sha512-DtBMo82pv1dFtUmHyr48beiuq792Sxohr+8Hm9zoxklYPfa6n0Z3Byjj2IV7bmr2IyqClnqEQhfgHJJ5QF0R5A==" - }, - "domhandler": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.2.2.tgz", - "integrity": "sha512-PzE9aBMsdZO8TK4BnuJwH0QT41wgMbRzuZrHUcpYncEjmQazq8QEaBWgLG7ZyC/DAZKEgglpIA6j4Qn/HmxS3w==", - "requires": { - "domelementtype": "^2.2.0" - } - }, - "domutils": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", - "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", - "requires": { - "dom-serializer": "^1.0.1", - "domelementtype": "^2.2.0", - "domhandler": "^4.2.0" - } - }, "dot-prop": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/dot-prop/-/dot-prop-6.0.1.tgz", @@ -3642,6 +4332,14 @@ "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "dev": true }, + "end-of-stream": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", + "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "requires": { + "once": "^1.4.0" + } + }, "enquirer": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.3.6.tgz", @@ -3651,11 +4349,6 @@ "ansi-colors": "^4.1.1" } }, - "entities": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", - "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==" - }, "env-paths": { "version": "2.2.1", "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", @@ -3819,6 +4512,22 @@ "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", "dev": true }, + "execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "requires": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + } + }, "fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -3850,6 +4559,11 @@ "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=", "dev": true }, + "fast-safe-stringify": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/fast-safe-stringify/-/fast-safe-stringify-2.1.1.tgz", + "integrity": "sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA==" + }, "fastq": { "version": "1.13.0", "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.13.0.tgz", @@ -3904,6 +4618,26 @@ "integrity": "sha512-JaTY/wtrcSyvXJl4IMFHPKyFur1sE9AUqc0QnhOaJ0CxHtAoIV8pYDzeEfAaNEtGkOfq4gr3LBFmdXW5mOQFnA==", "dev": true }, + "follow-redirects": { + "version": "1.14.4", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.14.4.tgz", + "integrity": "sha512-zwGkiSXC1MUJG/qmeIFH2HBJx9u0V46QGUe3YR1fXG8bXQxq7fLj0RjLZQ5nubr9qNJUZrH+xUcwXEoXNpfS+g==" + }, + "form-data": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-3.0.1.tgz", + "integrity": "sha512-RHkBKtLWUVwd7SqRIvCZMEvAMoGUp0XU+seQiZejj0COz3RI3hWP4sCv3gZWWLjJTd7rGwcsF5eKZGii0r/hbg==", + "requires": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + } + }, + "formidable": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/formidable/-/formidable-1.2.2.tgz", + "integrity": "sha512-V8gLm+41I/8kguQ4/o1D3RIHRmhYFG4pnNyonvua+40rqcEmT4+V71yaZ3B457xbbgCsCfjSPi65u/W6vK1U5Q==" + }, "fs-minipass": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", @@ -3917,6 +4651,11 @@ "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, "functional-red-black-tree": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz", @@ -3968,6 +4707,21 @@ } } }, + "get-intrinsic": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz", + "integrity": "sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q==", + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1" + } + }, + "get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==" + }, "glob": { "version": "7.1.7", "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.7.tgz", @@ -4021,10 +4775,42 @@ } } }, + "got": { + "version": "11.8.2", + "resolved": "https://registry.npmjs.org/got/-/got-11.8.2.tgz", + "integrity": "sha512-D0QywKgIe30ODs+fm8wMZiAcZjypcCodPNuMz5H9Mny7RJ+IjJ10BdmGW7OM7fHXP+O7r6ZwapQ/YQmMSvB0UQ==", + "requires": { + "@sindresorhus/is": "^4.0.0", + "@szmarczak/http-timer": "^4.0.5", + "@types/cacheable-request": "^6.0.1", + "@types/responselike": "^1.0.0", + "cacheable-lookup": "^5.0.3", + "cacheable-request": "^7.0.1", + "decompress-response": "^6.0.0", + "http2-wrapper": "^1.0.0-beta.5.2", + "lowercase-keys": "^2.0.0", + "p-cancelable": "^2.0.0", + "responselike": "^2.0.0" + } + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "requires": { + "function-bind": "^1.1.1" + } + }, "has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true + }, + "has-symbols": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.2.tgz", + "integrity": "sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw==" }, "has-unicode": { "version": "2.0.1", @@ -4036,16 +4822,10 @@ "resolved": "https://registry.npmjs.org/himalaya/-/himalaya-1.1.0.tgz", "integrity": "sha512-LLase1dHCRMel68/HZTFft0N0wti0epHr3nNY7ynpLbyZpmrKMQ8YIpiOV77TM97cNpC8Wb2n6f66IRggwdWPw==" }, - "htmlparser2": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-6.1.0.tgz", - "integrity": "sha512-gyyPk6rgonLFEDGoeRgQNaEUvdJ4ktTmmUh/h2t7s+M8oPpIPxgNACWa+6ESR57kXstwqPiCut0V8NRpcwgU7A==", - "requires": { - "domelementtype": "^2.0.1", - "domhandler": "^4.0.0", - "domutils": "^2.5.2", - "entities": "^2.0.0" - } + "http-cache-semantics": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.0.tgz", + "integrity": "sha512-carPklcUh7ROWRK7Cv27RPtdhYhUsela/ue5/jKzjegVvXDqM2ILE9Q2BGn9JZJh1g87cp56su/FgQSzcWS8cQ==" }, "http-response-object": { "version": "3.0.2", @@ -4062,6 +4842,15 @@ } } }, + "http2-wrapper": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/http2-wrapper/-/http2-wrapper-1.0.3.tgz", + "integrity": "sha512-V+23sDMr12Wnz7iTcDeJr3O6AIxlnvT/bmaAAAP/Xda35C90p9599p0F1eHR/N1KILWSoWVAiOMFjBBXaXSMxg==", + "requires": { + "quick-lru": "^5.1.1", + "resolve-alpn": "^1.0.0" + } + }, "https-proxy-agent": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.0.tgz", @@ -4071,6 +4860,11 @@ "debug": "4" } }, + "human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==" + }, "ignore": { "version": "4.0.6", "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz", @@ -4139,6 +4933,16 @@ "resolved": "https://registry.npmjs.org/is-obj/-/is-obj-2.0.0.tgz", "integrity": "sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w==" }, + "is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==" + }, + "is-unix": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-unix/-/is-unix-1.0.1.tgz", + "integrity": "sha512-8Iu9y/xCBmg1uwWV3J/jNl3udPHPAYyqGv4OKE/70O10U2qmt1v3/SRhSAW5+GiRpU2yZEnl+z1Oxm4A8arVrA==" + }, "isarray": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", @@ -4147,8 +4951,7 @@ "isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", - "dev": true + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" }, "js-tokens": { "version": "4.0.0", @@ -4166,6 +4969,11 @@ "esprima": "^4.0.0" } }, + "json-buffer": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", + "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==" + }, "json-schema-traverse": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", @@ -4178,6 +4986,14 @@ "integrity": "sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=", "dev": true }, + "keyv": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.0.3.tgz", + "integrity": "sha512-zdGa2TOpSZPq5mU6iowDARnMBZgtCqJ11dJROFi6tg6kTn4nuUdU09lFyLFSaHrWqpIJ+EBq4E8/Dc0Vx5vLdA==", + "requires": { + "json-buffer": "3.0.1" + } + }, "levn": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", @@ -4224,6 +5040,11 @@ "integrity": "sha1-WjUNoLERO4N+z//VgSy+WNbq4ZM=", "dev": true }, + "lowercase-keys": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-2.0.0.tgz", + "integrity": "sha512-tqNXrS78oMOE73NMxK4EMLQsQowWf8jKooH9g7xPavRT706R6bkQJ6DY2Te7QukaZsulxa30wQ7bk0pm4XiHmA==" + }, "lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -4256,12 +5077,22 @@ } } }, + "merge-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==" + }, "merge2": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", "dev": true }, + "methods": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", + "integrity": "sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4=" + }, "micromatch": { "version": "4.0.4", "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.4.tgz", @@ -4272,19 +5103,34 @@ "picomatch": "^2.2.3" } }, + "mime": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/mime/-/mime-2.5.2.tgz", + "integrity": "sha512-tqkh47FzKeCPD2PUiPB6pkbMzsCasjxAfC62/Wap5qrUWcb+sFasXUC5I3gYM5iBM8v/Qpn4UK0x+j0iHyFPDg==" + }, "mime-db": { - "version": "1.49.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.49.0.tgz", - "integrity": "sha512-CIc8j9URtOVApSFCQIF+VBkX1RwXp/oMMOrqdyXSBXq5RWNEsRfyj1kiRnQgmNXmHxPoFIxOroKA3zcU9P+nAA==" + "version": "1.50.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.50.0.tgz", + "integrity": "sha512-9tMZCDlYHqeERXEHO9f/hKfNXhre5dK2eE/krIvUjZbS2KPcqGDfNShIWS1uW9XOTKQKqK6qbeOci18rbfW77A==" }, "mime-types": { - "version": "2.1.32", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.32.tgz", - "integrity": "sha512-hJGaVS4G4c9TSMYh2n6SQAGrC4RnfU+daP8G7cSCmaqNjiOoUY0VHCMS42pxnQmVF1GWwFhbHWn3RIxCqTmZ9A==", + "version": "2.1.33", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.33.tgz", + "integrity": "sha512-plLElXp7pRDd0bNZHw+nMd52vRYjLwQjygaNg7ddJ2uJtTlmnTCjWuPKxVu6//AdaRuME84SvLW91sIkBqGT0g==", "requires": { - "mime-db": "1.49.0" + "mime-db": "1.50.0" } }, + "mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==" + }, + "mimic-response": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-1.0.1.tgz", + "integrity": "sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ==" + }, "miniget": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/miniget/-/miniget-4.2.1.tgz", @@ -4315,6 +5161,11 @@ "yallist": "^4.0.0" } }, + "mkdirp": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", + "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==" + }, "ms": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", @@ -4327,9 +5178,9 @@ "dev": true }, "node-addon-api": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-4.1.0.tgz", - "integrity": "sha512-Zz1o1BDX2VtduiAt6kgiUl8jX1Vm3NMboljFYKQJ6ee8AGfiTvM2mlZFI3xPbqjs80rCQgiVJI/DjQ/1QJ0HwA==" + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-3.2.1.tgz", + "integrity": "sha512-mmcei9JghVNDYydghQmeDX8KoAm0FAiYyIcUt/N4nhyAipB17pllZQDOJD2fotxABnt4Mdz+dKTO7eftLg4d0A==" }, "node-fetch": { "version": "2.6.2", @@ -4344,6 +5195,19 @@ "abbrev": "1" } }, + "normalize-url": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-6.1.0.tgz", + "integrity": "sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A==" + }, + "npm-run-path": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", + "requires": { + "path-key": "^3.0.0" + } + }, "npmlog": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-5.0.1.tgz", @@ -4355,19 +5219,16 @@ "set-blocking": "^2.0.0" } }, - "nth-check": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.0.1.tgz", - "integrity": "sha512-it1vE95zF6dTT9lBsYbxvqh0Soy4SPowchj0UBGj/V6cTPnXXtQOPUbhZ6CmGzAD/rW22LQK6E96pcdJXk4A4w==", - "requires": { - "boolbase": "^1.0.0" - } - }, "object-assign": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" }, + "object-inspect": { + "version": "1.11.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.11.0.tgz", + "integrity": "sha512-jp7ikS6Sd3GxQfZJPyH3cjcbJF6GZPClgdV+EFygjFLQ5FmW/dRUnTd9PQ9k0JhoNDabWFbpF1yCdSWCC6gexg==" + }, "once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -4376,6 +5237,14 @@ "wrappy": "1" } }, + "onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "requires": { + "mimic-fn": "^2.1.0" + } + }, "optionator": { "version": "0.9.1", "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.1.tgz", @@ -4410,6 +5279,37 @@ } } }, + "p-cancelable": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/p-cancelable/-/p-cancelable-2.1.1.tgz", + "integrity": "sha512-BZOr3nRQHOntUjTrH8+Lh54smKHoHyur8We1V8DSMVrl5A2malOOwuJRnKRDjSnkoeBh4at6BwEnb5I7Jl31wg==" + }, + "p-event": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/p-event/-/p-event-4.2.0.tgz", + "integrity": "sha512-KXatOjCRXXkSePPb1Nbi0p0m+gQAwdlbhi4wQKJPI1HsMQS9g+Sqp2o+QHziPr7eYJyOZet836KoHEVM1mwOrQ==", + "requires": { + "p-timeout": "^3.1.0" + } + }, + "p-finally": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", + "integrity": "sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4=" + }, + "p-reflect": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/p-reflect/-/p-reflect-2.1.0.tgz", + "integrity": "sha512-paHV8NUz8zDHu5lhr/ngGWQiW067DK/+IbJ+RfZ4k+s8y4EKyYCz8pGYWjxCg35eHztpJAt+NUgvN4L+GCbPlg==" + }, + "p-timeout": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/p-timeout/-/p-timeout-3.2.0.tgz", + "integrity": "sha512-rhIwUycgwwKcP9yTOOFK/AKsAopjjCakVqLHePO3CC6Mir1Z99xT+R63jZxAT5lFZLa2inS5h+ZS2GvR99/FBg==", + "requires": { + "p-finally": "^1.0.0" + } + }, "parent-module": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", @@ -4424,19 +5324,6 @@ "resolved": "https://registry.npmjs.org/parse-cache-control/-/parse-cache-control-1.0.1.tgz", "integrity": "sha1-juqz5U+laSD+Fro493+iGqzC104=" }, - "parse5": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/parse5/-/parse5-6.0.1.tgz", - "integrity": "sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw==" - }, - "parse5-htmlparser2-tree-adapter": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-6.0.1.tgz", - "integrity": "sha512-qPuWvbLgvDGilKc5BoicRovlT4MtYT6JfJyBOMDsKoiT+GiuP5qyrPCnR9HcPECIJJmZh5jRndyNThnhhb/vlA==", - "requires": { - "parse5": "^6.0.1" - } - }, "path-is-absolute": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", @@ -4445,8 +5332,7 @@ "path-key": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", - "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", - "dev": true + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==" }, "path-type": { "version": "4.0.0", @@ -4482,18 +5368,40 @@ "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==" }, + "pump": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", + "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "requires": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, "punycode": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", "dev": true }, + "qs": { + "version": "6.10.1", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.10.1.tgz", + "integrity": "sha512-M528Hph6wsSVOBiYUnGf+K/7w0hNshs/duGsNXPUCLH5XAqjEtiPGwNONLV0tBH8NoGb0mvD5JubnUTrujKDTg==", + "requires": { + "side-channel": "^1.0.4" + } + }, "queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", "dev": true }, + "quick-lru": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-5.1.1.tgz", + "integrity": "sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==" + }, "readable-stream": { "version": "2.3.7", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", @@ -4520,12 +5428,25 @@ "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", "dev": true }, + "resolve-alpn": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/resolve-alpn/-/resolve-alpn-1.2.1.tgz", + "integrity": "sha512-0a1F4l73/ZFZOakJnQ3FvkJ2+gSTQWz/r2KE5OdDY0TxPm5h4GkqkWWfM47T7HsbnOtcJVEF4epCVy6u7Q3K+g==" + }, "resolve-from": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", "dev": true }, + "responselike": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/responselike/-/responselike-2.0.0.tgz", + "integrity": "sha512-xH48u3FTB9VsZw7R+vvgaKeLKzT6jOogbQhEe/jewwnZgzPcnyWui2Av6JpoYZF/91uueC+lqhWqeURw5/qhCw==", + "requires": { + "lowercase-keys": "^2.0.0" + } + }, "reusify": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", @@ -4576,7 +5497,6 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", - "dev": true, "requires": { "shebang-regex": "^3.0.0" } @@ -4584,8 +5504,17 @@ "shebang-regex": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", - "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", - "dev": true + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==" + }, + "side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "requires": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + } }, "signal-exit": { "version": "3.0.3", @@ -4609,14 +5538,12 @@ "is-fullwidth-code-point": "^3.0.0" } }, - "soundcloud-scraper": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/soundcloud-scraper/-/soundcloud-scraper-5.0.2.tgz", - "integrity": "sha512-QAPvRIG4eefc7JdmCQCG/QEhm4D90XgHbe9lJMHmKIxU0INdAD2LycUR1m0mCIKF3F2dk4NvGEkxGfVLI8Af+A==", + "soundcloud.ts": { + "version": "0.4.5", + "resolved": "https://registry.npmjs.org/soundcloud.ts/-/soundcloud.ts-0.4.5.tgz", + "integrity": "sha512-WAQN687lCs7ig4xciXaNSX3iZ5+XWM5l00jQx3edVsw8ySjPyIymHuSKeHZJBrpKCZbPnnvzEWaBYDK7+eYDCw==", "requires": { - "cheerio": "^1.0.0-rc.10", - "m3u8stream": "^0.8.4", - "node-fetch": "^2.6.1" + "axios": "^0.21.1" } }, "spotify-uri": { @@ -4634,6 +5561,14 @@ "spotify-uri": "~2.2.0" } }, + "spotify-web-api-node": { + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/spotify-web-api-node/-/spotify-web-api-node-5.0.2.tgz", + "integrity": "sha512-r82dRWU9PMimHvHEzL0DwEJrzFk+SMCVfq249SLt3I7EFez7R+jeoKQd+M1//QcnjqlXPs2am4DFsGk8/GCsrA==", + "requires": { + "superagent": "^6.1.0" + } + }, "sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", @@ -4668,16 +5603,52 @@ "ansi-regex": "^5.0.0" } }, + "strip-final-newline": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==" + }, "strip-json-comments": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", "dev": true }, + "superagent": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/superagent/-/superagent-6.1.0.tgz", + "integrity": "sha512-OUDHEssirmplo3F+1HWKUrUjvnQuA+nZI6i/JJBdXb5eq9IyEQwPyPpqND+SSsxf6TygpBEkUjISVRN4/VOpeg==", + "requires": { + "component-emitter": "^1.3.0", + "cookiejar": "^2.1.2", + "debug": "^4.1.1", + "fast-safe-stringify": "^2.0.7", + "form-data": "^3.0.0", + "formidable": "^1.2.2", + "methods": "^1.1.2", + "mime": "^2.4.6", + "qs": "^6.9.4", + "readable-stream": "^3.6.0", + "semver": "^7.3.2" + }, + "dependencies": { + "readable-stream": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.0.tgz", + "integrity": "sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA==", + "requires": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + } + } + } + }, "supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, "requires": { "has-flag": "^4.0.0" } @@ -4727,13 +5698,6 @@ "minizlib": "^2.1.1", "mkdirp": "^1.0.3", "yallist": "^4.0.0" - }, - "dependencies": { - "mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==" - } } }, "text-table": { @@ -4821,7 +5785,6 @@ "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "dev": true, "requires": { "isexe": "^2.0.0" } @@ -4884,24 +5847,6 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" - }, - "youtube-sr": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/youtube-sr/-/youtube-sr-4.1.7.tgz", - "integrity": "sha512-OKbm+561Fq5RlnUtJBmPhnyfS6Zon44zdPhY1v/Y9vpAHzqdfxomD43yc0ZQv6zNsVzSlAkGeWhoweNd6DUUjQ==", - "requires": { - "node-fetch": "^2.6.1" - } - }, - "ytdl-core": { - "version": "4.9.1", - "resolved": "https://registry.npmjs.org/ytdl-core/-/ytdl-core-4.9.1.tgz", - "integrity": "sha512-6Jbp5RDhUEozlaJQAR+l8oV8AHsx3WUXxSyPxzE6wOIAaLql7Hjiy0ZM58wZoyj1YEenlEPjEqcJIjKYKxvHtQ==", - "requires": { - "m3u8stream": "^0.8.3", - "miniget": "^4.0.0", - "sax": "^1.1.3" - } } } } diff --git a/package.json b/package.json index b1c3c64..0419697 100644 --- a/package.json +++ b/package.json @@ -29,15 +29,15 @@ }, "homepage": "https://github.com/boomermath/bop-js#readme", "dependencies": { - "@discordjs/opus": "^0.6.0", + "@discordjs/opus": "^0.5.3", "@discordjs/voice": "^0.6.0", - "chalk": "^4.1.2", - "discord-player": "^5.1.0", - "discord-ytdl-core": "^5.0.4", - "discord.js": "^13.1.0", + "@distube/soundcloud": "^0.2.2", + "@distube/spotify": "^0.6.4", + "discord.js": "^13.2.0", + "distube": "^3.0.0-beta.39", "dotenv": "^10.0.0", "ffmpeg-static": "^4.4.0", - "ytdl-core": "^4.9.1" + "libsodium-wrappers": "^0.7.9" }, "devDependencies": { "@typescript-eslint/eslint-plugin": "^4.31.1", diff --git a/src/commands/disconnect.ts b/src/commands/disconnect.ts index acfb725..e2becf2 100644 --- a/src/commands/disconnect.ts +++ b/src/commands/disconnect.ts @@ -12,10 +12,9 @@ export default class extends Command { }); } - public async main(message: Message, args: string[]): Promise { - this.client.player.emit( - "queueEnd", - this.client.player.getQueue(message.guild!) - ); + public async main(message: Message): Promise { + const queue = this.client.player.getQueue(message.guild!.id)!; + + queue.stop(); } -} +} \ No newline at end of file diff --git a/src/commands/filter.ts b/src/commands/filter.ts index 53d9349..a7bce60 100644 --- a/src/commands/filter.ts +++ b/src/commands/filter.ts @@ -1,18 +1,26 @@ -import { AudioFilters, Queue } from "discord-player"; import { Message } from "discord.js"; +import { defaultFilters } from "distube"; import BopClient from "../../lib/Client"; import { Command } from "../../lib/Modules"; import { EMBED_COLOR, Notification } from "../../lib/util/Embeds"; -import Util, { QueueMetadata } from "../../lib/util/Util"; +const distubeDefaultFilters = Object.keys(defaultFilters); const filterAliases: Record = { - bassboost: "bassboost", bb: "bassboost", nc: "nightcore", vw: "vaporwave", - nm: "normalizer2", - "8d": "8D", - "8D": "8D", + fl: "flanger", + ec: "echo", + ha: "haas", + rv: "reverse", + mc: "mcompand", + sr: "surround", + ph: "phaser", + tm: "tremolo", + ew: "earwax", + kk: "karaoke", + "8d": "3D", + "8D": "3D", }; export default class extends Command { @@ -26,78 +34,50 @@ export default class extends Command { }); } - private formatFilter(arg: string): string { - return arg - .split("_") - .map((e) => Util.toTitleCase(e)) - .join(" "); - } - public async main(message: Message, args: string[]): Promise { - const queue: Queue = this.client.player.getQueue( - message.guild! - ); - const queueFiltersEnabled = queue.getFiltersEnabled(); + const queue = this.client.player.getQueue(message.guild!.id)!; - if (args.length > 3) { - message.channel.send({ - embeds: [new Notification(":x: No more than three at a time!")], - }); - } else if (!args.length) { - const formattedQueueFilters = Object.entries( - queue.metadata?.filters! - ).map( - (e) => - `**${this.formatFilter(e[0])}**: ${e[1] ? "Enabled" : "Disabled"}` + if (!args.length) { + const filterEntries = distubeDefaultFilters.map( + (f) => + `**${f[0].toUpperCase()}${f.slice(1)}**: *${ + queue.filters.includes(f) ? "Enabled" : "Disabled" + }*` ); - message.channel.send({ + return void message.channel.send({ embeds: [ { title: `Filters for ${message.guild?.name}`, - description: formattedQueueFilters.join("\n"), + description: filterEntries.join("\n"), color: EMBED_COLOR, fields: [ { - name: "Toggle Filters", - value: `To toggle filters, do ${this.client.prefix}filter <...filters>`, + name: "Add Filters", + value: `To add filters, use \`${this.client.prefix}filter \``, }, ], }, ], }); - } else { - const filters = args.map( - (arg) => - filterAliases[arg.toLowerCase()] ?? - AudioFilters.names.find((a) => a.includes(arg.toLowerCase())) ?? - `Invalid filter: ${arg}` - ); - const invalidFilter = filters.find((f) => f.startsWith("Invalid")); + } + + const filterArguments = args.map( + (a) => filterAliases[a.toLowerCase()] || a.toLowerCase() + ); - if (invalidFilter) { + for (const filter of filterArguments) { + if (!distubeDefaultFilters.includes(filter)) { return void message.channel.send({ - embeds: [new Notification(invalidFilter)], + embeds: [new Notification(`"${filter}" is not a valid filter!`)], }); } + } - filters.map( - (filter) => - (queue.metadata!.filters[filter] = !queue.metadata?.filters[filter]) - ); + queue.setFilter(filterArguments); - queue.setPaused(true); - await queue.setFilters(queue.metadata?.filters); - - message.channel.send({ - embeds: [ - new Notification( - `Toggled ${filters.join(", ")} filter${ - filters.length > 1 ? "s" : "" - }!` - ), - ], - }); - } + message.channel.send({ + embeds: [new Notification(`Toggled ${filterArguments.join(", ")}!`)], + }); } } diff --git a/src/commands/loop.ts b/src/commands/loop.ts index 8a1c239..5830374 100644 --- a/src/commands/loop.ts +++ b/src/commands/loop.ts @@ -1,16 +1,29 @@ -import { QueueRepeatMode } from "discord-player"; import { Message } from "discord.js"; +import { RepeatMode } from "distube"; import BopClient from "../../lib/Client"; import { Command } from "../../lib/Modules"; import { Notification } from "../../lib/util/Embeds"; -const options: Record = { - o: QueueRepeatMode.OFF, - off: QueueRepeatMode.OFF, - t: QueueRepeatMode.TRACK, - track: QueueRepeatMode.TRACK, - q: QueueRepeatMode.QUEUE, - queue: QueueRepeatMode.QUEUE, +const options: Record = { + o: RepeatMode.DISABLED, + off: RepeatMode.DISABLED, + t: RepeatMode.SONG, + track: RepeatMode.SONG, + s: RepeatMode.SONG, + song: RepeatMode.SONG, + q: RepeatMode.QUEUE, + queue: RepeatMode.QUEUE, +}; + +const getModeName = (mode: RepeatMode): string => { + switch (mode) { + case RepeatMode.DISABLED: + return "off"; + case RepeatMode.SONG: + return "song"; + default: + return "queue"; + } }; export default class extends Command { @@ -24,19 +37,9 @@ export default class extends Command { }); } - private getModeName(mode: QueueRepeatMode): string { - switch (mode) { - case QueueRepeatMode.OFF: - return "off"; - case QueueRepeatMode.TRACK: - return "track"; - default: - return "queue"; - } - } - public async main(message: Message, args: string[]): Promise { - const queue = this.client.player.getQueue(message.guild!); + const queue = this.client.player.getQueue(message.guild!)!; + if (args.length) { const loopMode = options[args[0].toLowerCase()]; @@ -53,9 +56,8 @@ export default class extends Command { message.channel.send({ embeds: [ new Notification( - `${ - args.length ? "Loop mode set to" : "Current loop mode is" - } *${this.getModeName(queue.repeatMode)}*` + `${args.length ? "Loop mode set to" : "Current loop mode is" + } *${getModeName(queue.repeatMode)}*` ), ], }); diff --git a/src/commands/np.ts b/src/commands/np.ts index 2adeb49..f3d9cc9 100644 --- a/src/commands/np.ts +++ b/src/commands/np.ts @@ -3,6 +3,14 @@ import BopClient from "../../lib/Client"; import { Command } from "../../lib/Modules"; import { EMBED_COLOR } from "../../lib/util/Embeds"; +const toSeconds = (f: string): number => + f.split(":").reduce((acc, time) => 60 * acc + parseInt(time), 0); + +const toFormatted = (s: number): string => { + const formatted = new Date(s * 1000).toISOString().substr(11, 8); + return formatted.startsWith("00:") ? formatted.slice(3) : formatted; +}; + export default class extends Command { public constructor(client: BopClient, directory: string) { super(client, directory, { @@ -13,23 +21,42 @@ export default class extends Command { }); } - public async main(message: Message, args: string[]): Promise { - const queue = this.client.player.getQueue(message.guild!); + public async main(message: Message): Promise { + const queue = this.client.player.getQueue(message.guild!)!; + const current = queue.songs[0]; + const timeLeft = + current.formattedDuration === "Live" + ? "Live" + : toFormatted( + toSeconds(current.formattedDuration!) - queue.currentTime + ); message.channel.send({ embeds: [ { title: "Now Playing", - description: `**[${queue.current.title}](${queue.current.url})** by ***${queue.current.author}***`, + description: `**[${current.name}](${current.url})** by ***[${current.uploader.name}](${current.uploader.url})***`, color: EMBED_COLOR, author: { - name: queue.current.requestedBy.username, - icon_url: queue.current.requestedBy.displayAvatarURL(), + name: current.user?.username, + icon_url: current.user?.displayAvatarURL(), }, thumbnail: { - url: queue.current.thumbnail, + url: current.thumbnail, }, - fields: [{ name: "\u200b", value: queue.createProgressBar() }], + fields: [ + { + name: "Time elapsed", + value: queue.formattedCurrentTime, + inline: true, + }, + { name: "Time left", value: timeLeft, inline: true }, + { + name: "Time total", + value: current.formattedDuration!, + inline: true, + }, + ], }, ], }); diff --git a/src/commands/pause.ts b/src/commands/pause.ts index c3cca81..6ea96af 100644 --- a/src/commands/pause.ts +++ b/src/commands/pause.ts @@ -13,17 +13,16 @@ export default class extends Command { }); } - public async main(message: Message, args: string[]): Promise { - const queue = this.client.player.getQueue(message.guild!); + public async main(message: Message): Promise { + const queue = this.client.player.getQueue(message.guild!)!; - if (!queue.playing) { + if (queue.paused) { return void message.channel.send({ embeds: [new Notification("Music is already paused!")], }); } - queue.playing = false; - queue.setPaused(true); + queue.pause(); const resumeButton = new MessageActionRow().addComponents( new MessageButton() diff --git a/src/commands/play.ts b/src/commands/play.ts index 5cf5010..ded1847 100644 --- a/src/commands/play.ts +++ b/src/commands/play.ts @@ -1,88 +1,19 @@ -import { AudioFilters, Queue, Track } from "discord-player"; -import { QueryResolver, QueryType } from "discord-player"; -import { GuildChannelResolvable, Message } from "discord.js"; -import { validateURL } from "ytdl-core"; +import { Message } from "discord.js"; import BopClient from "../../lib/Client"; import { Command } from "../../lib/Modules"; -import { Notification } from "../../lib/util/Embeds"; -import Util, { QueueMetadata } from "../../lib/util/Util"; export default class extends Command { - public constructor(client: BopClient, directory: string) { - super(client, directory, { - name: "play", - description: "Play music!", - usage: ["query"], - aliases: ["p"], - cooldown: 1, - }); - } - - public async main(message: Message, args: string[]): Promise { - const player = this.client.player; - - if (!args.length) { - return void message.channel.send({ - embeds: [new Notification("Give me something to play!")], - }); - } - - const input = args.join(" "); - const queueExists = player.getQueue(message.guild!); - const queueCast = queueExists - ? queueExists - : player.createQueue(message.guild!, { - metadata: { - channel: message.channel, - filters: { ...Util.defaultFilters }, - }, - autoSelfDeaf: true, - initialVolume: 75, - leaveOnEmptyCooldown: 3000, + public constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "play", + description: "Play music!", + usage: ["query"], + aliases: ["p"], + cooldown: 1, }); - const queue = queueCast as Queue; - - queue.metadata!.filters.normalizer2 = true; - - let searchEngine = QueryResolver.resolve(input); - - searchEngine = - searchEngine === QueryType.YOUTUBE_VIDEO - ? !validateURL(input) - ? QueryType.YOUTUBE_SEARCH - : QueryType.YOUTUBE_VIDEO - : searchEngine; - - const song = await player.search(input, { - requestedBy: message.author, - searchEngine: searchEngine, - }); - - if (!(song.tracks[0] instanceof Track)) { - return void message.channel.send({ - embeds: [new Notification("Couldn't find that song!")], - }); } - if (!queueExists) { - try { - await queue.connect( - message.member?.voice.channel as GuildChannelResolvable - ); - } catch { - this.client.player.deleteQueue(queue.guild); - return void message.channel.send("Couldn't connect!"); - } - } - - song.playlist - ? queue.addTracks(song.tracks) - : queue.addTrack(song.tracks[0]); - - if (!queueExists) { - await queue.play().then(async () => { - await queue.setFilters(queue.metadata?.filters); - }); + public async main(message: Message, args: string[]): Promise { + this.client.player.play(message, args.join(" ")); } - } } diff --git a/src/commands/queue.ts b/src/commands/queue.ts index 76443b4..51fb238 100644 --- a/src/commands/queue.ts +++ b/src/commands/queue.ts @@ -1,10 +1,22 @@ -import { Track } from "discord-player"; import { EmbedField, Message } from "discord.js"; +import { Song } from "distube"; import BopClient from "../../lib/Client"; import { Command } from "../../lib/Modules"; import { EMBED_COLOR } from "../../lib/util/Embeds"; -export default class extends Command { +const entry = (track: Song, index: number): EmbedField => { + return { + name: index === 0 ? "Queued" : "\u200b", + value: `**${index === 0 ? "Now Playing:" : `${index + 1}.`} [${ + track.name + }](${track.url})** by ***[${track.uploader.name}](${ + track.uploader.url + })*** | \`${track.formattedDuration}\` | ${track.user}`, + inline: false, + }; +}; + +export default class extends Command { public constructor(client: BopClient, directory: string) { super(client, directory, { name: "queue", @@ -14,23 +26,11 @@ export default class extends Command { }); } - private entry(track: Track, index: number): EmbedField { - return { - name: index === 0 ? "Queued" : "\u200b", - value: `**${index < 0 ? "Now Playing:" : `${index + 1}.`} [${ - track.title - }](${track.url})** by ***${track.author}*** | \`${ - track.duration - }\` ${track.views > 0 ? `| **${track.views.toLocaleString()} views**` : ""}`, - inline: false, - }; - } - public async main(message: Message): Promise { - const queue = this.client.player.getQueue(message.guild!); - const queueEntries = queue.tracks.map(this.entry); + const queue = this.client.player.getQueue(message.guild!)!; + const queueEntries = queue.songs.map(entry); - if (!queueEntries.length) { + if (queueEntries.length < 2) { queueEntries.push({ name: "Nothing queued!", value: "Add some music!", @@ -42,7 +42,7 @@ export default class extends Command { embeds: [ { title: `Queue for ${message.guild?.name}`, - description: this.entry(queue.current, -1).value, + description: queueEntries.shift()?.value, color: EMBED_COLOR, fields: queueEntries, }, diff --git a/src/commands/remove.ts b/src/commands/remove.ts index 258c7a1..e18fe40 100644 --- a/src/commands/remove.ts +++ b/src/commands/remove.ts @@ -15,18 +15,18 @@ export default class extends Command { } public async main(message: Message, args: string[]): Promise { - const queue = this.client.player.getQueue(message.guild!); - const index = parseInt(args[0]); + const queue = this.client.player.getQueue(message.guild!)!; + const index = parseInt(args[0]) - 1; - if (!index || index < 0 || index > queue.tracks.length) { + if (!index || index < 1 || index > queue.songs.length) { message.channel.send({ embeds: [new Notification("That's not a valid song to remove!")], }); } else { - const song = queue.remove(index - 1); + const song = queue.songs.splice(index, 1)[0]; message.channel.send({ - embeds: [new Notification(`Removed *[${song.title}](${song.url})*`)], + embeds: [new Notification(`Removed *[${song.name}](${song.url})*!`)], }); } } diff --git a/src/commands/resume.ts b/src/commands/resume.ts index 6272a2e..ec310e1 100644 --- a/src/commands/resume.ts +++ b/src/commands/resume.ts @@ -14,16 +14,15 @@ export default class extends Command { } public async main(message: Message, args: string[]): Promise { - const queue = this.client.player.getQueue(message.guild!); + const queue = this.client.player.getQueue(message.guild!)!; - if (queue.playing) { + if (!queue.paused) { return void message.channel.send({ embeds: [new Notification("Music is already playing!")], }); } - queue.playing = true; - queue.setPaused(false); + queue.resume(); const pauseButton = new MessageActionRow().addComponents( new MessageButton() diff --git a/src/commands/shuffle.ts b/src/commands/shuffle.ts index a350d20..d5b55f4 100644 --- a/src/commands/shuffle.ts +++ b/src/commands/shuffle.ts @@ -14,7 +14,7 @@ export default class extends Command { } public async main(message: Message, args: string[]): Promise { - const queue = this.client.player.getQueue(message.guild!); + const queue = this.client.player.getQueue(message.guild!)!; queue.shuffle(); message.channel.send({ embeds: [new Notification("Queue shuffled!")] }); } diff --git a/src/commands/skip.ts b/src/commands/skip.ts index 358aa3d..015c9fc 100644 --- a/src/commands/skip.ts +++ b/src/commands/skip.ts @@ -15,21 +15,18 @@ export default class extends Command { } public async main(message: Message, args: string[]): Promise { - const queue = this.client.player.getQueue(message.guild!); + const queue = this.client.player.getQueue(message.guild!)!; if (!args.length) return void queue.skip(); const index = parseInt(args[0]) - 1; - if (index < 0 || index > queue.tracks.length) { + if (index < 0 || index > queue.songs.length) { return void message.channel.send({ embeds: [new Notification("Invalid number to jump to!")], }); } - this.client.console.log(index); - this.client.console.log(queue.tracks) - queue.jump(index); } } diff --git a/src/commands/volume.ts b/src/commands/volume.ts index 90a537d..7eedd62 100644 --- a/src/commands/volume.ts +++ b/src/commands/volume.ts @@ -15,16 +15,16 @@ export default class extends Command { } public async main(message: Message, args: string[]): Promise { - const queue = this.client.player.getQueue(message.guild!); + const queue = this.client.player.getQueue(message.guild!)!; const volume = parseInt(args[0]); - if (!volume) { + if (!volume && volume !== 0) { message.channel.send({ embeds: [new Notification(`Volume is ${queue.volume}`)], }); } else if (volume < 0 || volume > 100) { message.channel.send({ - embeds: [new Notification("Invalid volume!")], + embeds: [new Notification("Volume can only be between 0-100!")], }); } else { queue.setVolume(volume); diff --git a/src/events/client/interaction.ts b/src/events/client/interaction.ts index 7f11960..e330732 100644 --- a/src/events/client/interaction.ts +++ b/src/events/client/interaction.ts @@ -1,37 +1,37 @@ -import { Awaited, Interaction, Message } from "discord.js"; +import { Interaction, Message } from "discord.js"; import BopClient from "../../../lib/Client"; import { Event } from "../../../lib/Modules"; -export default class InteractionEvent extends Event { - constructor(client: BopClient, directory: string) { - super(client, directory, { - name: "interactionCreate", - emitter: "client", - }); - } +export default class extends Event { + constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "interactionCreate", + emitter: "client", + }); + } - public main(interaction: Interaction): Awaited { - if (!interaction.isButton()) return; - interaction.deferUpdate(); + public main(interaction: Interaction): void { + if (!interaction.isButton()) return; + interaction.deferUpdate(); - const command = this.client.commands.get(interaction.customId); + const command = this.client.commands.get(interaction.customId); - if (!command) return; + if (!command) return; - const inhibited = this.client.inhibitors.run( + const inhibited = this.client.inhibitors.run( interaction.message as Message, command - ); + ); - if (inhibited) return; + if (inhibited) return; - try { - command.main(interaction.message as Message, []); - } catch (err) { - this.client.console.error(err); - interaction.reply( - "The button went boom boom, ping boomermath :rolling_eyes:" - ); + try { + command.main(interaction.message as Message, []); + } catch (err) { + this.client.console.error(err); + interaction.reply( + "The button went boom boom, ping boomermath :rolling_eyes:" + ); + } } - } } diff --git a/src/events/client/message.ts b/src/events/client/message.ts index 89fb3ff..ac88d18 100644 --- a/src/events/client/message.ts +++ b/src/events/client/message.ts @@ -1,37 +1,53 @@ -import { Awaited, Message } from "discord.js"; +import { Message } from "discord.js"; import BopClient from "../../../lib/Client"; +import { Notification } from "../../../lib/util/Embeds"; import { Event } from "../../../lib/Modules"; -export default class MessageEvent extends Event { - constructor(client: BopClient, directory: string) { - super(client, directory, { - name: "messageCreate", - emitter: "client" - }); +export default class extends Event { + constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "messageCreate", + emitter: "client", + }); + } + + public main(message: Message): void { + if (this.client.hasMention(message.content)) { + return void message.channel.send({ + embeds: [ + new Notification( + `Hi!\n I'm *Bop*, the very cool music bot!\nTo get started, type \`${this.client.prefix}help\`` + ), + ], + }); } - public main(message: Message): Awaited { - if (message.author.bot || !message.guild || !message.content.startsWith(this.client.prefix)) return; + if ( + message.author.bot || + !message.guild || + !message.content.startsWith(this.client.prefix) + ) + return; - const [cmd, ...args] = message.content - .slice(this.client.prefix.length) - .trim() - .split(/ +/); - const command = this.client.commands.get(cmd.toLowerCase()); + const [cmd, ...args] = message.content + .slice(this.client.prefix.length) + .trim() + .split(/ +/); + const command = this.client.commands.get(cmd.toLowerCase()); - if (!command) return; + if (!command) return; - const isInhibited = this.client.inhibitors.run(message, command); + const isInhibited = this.client.inhibitors.run(message, command); - if (isInhibited) return; + if (isInhibited) return; - try { - command.main(message, args); - } catch (err) { - this.client.console.error(err); - message.channel.send( - "There was an error, ping boomermath repeatedly to fix it." - ); - } + try { + command.main(message, args); + } catch (err) { + this.client.console.error(err); + message.channel.send( + "There was an error, ping boomermath repeatedly to fix it." + ); } + } } diff --git a/src/events/client/ready.ts b/src/events/client/ready.ts index 72a6a96..c48f3cf 100644 --- a/src/events/client/ready.ts +++ b/src/events/client/ready.ts @@ -1,8 +1,7 @@ -import { Awaited } from "discord.js"; import BopClient from "../../../lib/Client"; import { Event } from "../../../lib/Modules"; -export default class ReadyEvent extends Event { +export default class extends Event { constructor(client: BopClient, directory: string) { super(client, directory, { name: "ready", @@ -11,11 +10,11 @@ export default class ReadyEvent extends Event { }); } - public main(): Awaited { + public main(): void { this.client.console.log("Ready!"); this.client.user!.setPresence({ - activities: [{ name: "with bop!" }], + activities: [{ name: `with ${this.client.prefix}` }], status: "idle", }); } diff --git a/src/events/player/addList.ts b/src/events/player/addList.ts new file mode 100644 index 0000000..3a2fea5 --- /dev/null +++ b/src/events/player/addList.ts @@ -0,0 +1,23 @@ +import { Playlist, Queue } from "distube"; +import BopClient from "../../../lib/Client"; +import { Event } from "../../../lib/Modules"; +import { MusicEmbed } from "../../../lib/util/Embeds"; +import Util from "../../../lib/util/Util"; + +export default class extends Event { + constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "addList", + emitter: "player", + }); + } + + public main(queue: Queue, playlist: Playlist): void { + const playlistEmbed = new MusicEmbed(playlist); + + return void queue.textChannel?.send({ + embeds: [playlistEmbed], + components: [Util.buildDefaultActionRow()], + }); + } +} diff --git a/src/events/player/addSong.ts b/src/events/player/addSong.ts new file mode 100644 index 0000000..6a63421 --- /dev/null +++ b/src/events/player/addSong.ts @@ -0,0 +1,23 @@ +import { Queue, Song } from "distube"; +import BopClient from "../../../lib/Client"; +import { Event } from "../../../lib/Modules"; +import { MusicEmbed } from "../../../lib/util/Embeds"; +import Util from "../../../lib/util/Util"; + +export default class extends Event { + constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "addSong", + emitter: "player", + }); + } + + public main(queue: Queue, song: Song): void { + const songEmbed = new MusicEmbed(song); + + return void queue.textChannel?.send({ + embeds: [songEmbed], + components: [Util.buildDefaultActionRow()], + }); + } +} diff --git a/src/events/player/deleteQueue.ts b/src/events/player/deleteQueue.ts new file mode 100644 index 0000000..4dbf38e --- /dev/null +++ b/src/events/player/deleteQueue.ts @@ -0,0 +1,19 @@ +import { Queue } from "distube"; +import BopClient from "../../../lib/Client"; +import { Event } from "../../../lib/Modules"; +import { Notification } from "../../../lib/util/Embeds"; + +export default class extends Event { + constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "deleteQueue", + emitter: "player", + }); + } + + public main(queue: Queue): void { + return void queue.textChannel?.send({ + embeds: [new Notification("Disconnected!")], + }); + } +} diff --git a/src/events/player/error.ts b/src/events/player/error.ts index f68b476..2f5370e 100644 --- a/src/events/player/error.ts +++ b/src/events/player/error.ts @@ -1,27 +1,25 @@ -import { Queue } from "discord-player"; import { TextChannel } from "discord.js"; import BopClient from "../../../lib/Client"; import { Event } from "../../../lib/Modules"; import { Notification } from "../../../lib/util/Embeds"; -import { QueueMetadata } from "../../../lib/util/Util"; -export default class BotDisconnectEvent extends Event { - constructor(client: BopClient, directory: string) { - super(client, directory, { - name: "error", - emitter: "player", - }); - } +export default class extends Event { + constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "error", + emitter: "player", + }); + } - public main(queue: Queue, error: Error): void { - this.client.console.error(error); + public main(channel: TextChannel, error: Error): void { + let err = "Error occurred!"; + + if (error.stack?.includes("Sign in to confirm your age")) { + err = "Age-restricted video!"; + } - if (error.message.includes("403")) return; - - this.client.player.deleteQueue(queue.guild); - - queue.metadata?.channel.send({ - embeds: [new Notification("An error occurred, disconnecting!")], - }); - } + channel.send({ embeds: [new Notification(err)] }); + this.client.console.error("Player Error!"); + this.client.console.error(error); + } } diff --git a/src/events/player/initQueue.ts b/src/events/player/initQueue.ts new file mode 100644 index 0000000..930b9fa --- /dev/null +++ b/src/events/player/initQueue.ts @@ -0,0 +1,16 @@ +import { Queue } from "distube"; +import BopClient from "../../../lib/Client"; +import { Event } from "../../../lib/Modules"; + +export default class extends Event { + constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "initQueue", + emitter: "player", + }); + } + + public main(queue: Queue): void { + queue.setVolume(80); + } +} diff --git a/src/events/player/playSong.ts b/src/events/player/playSong.ts new file mode 100644 index 0000000..08c5f8b --- /dev/null +++ b/src/events/player/playSong.ts @@ -0,0 +1,23 @@ +import { Queue, Song } from "distube"; +import BopClient from "../../../lib/Client"; +import { Event } from "../../../lib/Modules"; +import { MusicEmbed } from "../../../lib/util/Embeds"; +import Util from "../../../lib/util/Util"; + +export default class extends Event { + constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "playSong", + emitter: "player", + }); + } + + public main(queue: Queue, song: Song): void { + const songEmbed = new MusicEmbed(song, true); + + return void queue.textChannel?.send({ + embeds: [songEmbed], + components: [Util.buildDefaultActionRow()], + }); + } +} diff --git a/src/events/player/searchNoResult.ts b/src/events/player/searchNoResult.ts new file mode 100644 index 0000000..84d04ac --- /dev/null +++ b/src/events/player/searchNoResult.ts @@ -0,0 +1,19 @@ +import { Message } from "discord.js"; +import BopClient from "../../../lib/Client"; +import { Event } from "../../../lib/Modules"; +import { Notification } from "../../../lib/util/Embeds"; + +export default class extends Event { + constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "searchNoResult", + emitter: "player", + }); + } + + public main(message: Message, query: string): void { + message.channel.send({ + embeds: [new Notification(`Couldn't find anything for "${query}"!`)] + }); + } +} diff --git a/src/inhibitors/voiceChannel.ts b/src/inhibitors/voiceChannel.ts index e97974d..1bf120a 100644 --- a/src/inhibitors/voiceChannel.ts +++ b/src/inhibitors/voiceChannel.ts @@ -4,24 +4,24 @@ import { Command, Inhibitor } from "../../lib/Modules"; import { Notification } from "../../lib/util/Embeds"; export default class VoiceChannelInhibitor extends Inhibitor { - constructor(client: BopClient, directory: string) { - super(client, directory, { - name: "voiceChannel", - }); - } + constructor(client: BopClient, directory: string) { + super(client, directory, { + name: "voiceChannel", + }); + } - check(message: Message, command: Command): boolean { - if (!message.guild?.me?.voice.channel) return false; + check(message: Message, command: Command): boolean { + if (!message.guild?.me?.voice.channel) return false; - return ( - !["queue", "nowplaying", "help"].includes(command.name) && + return ( + !["queue", "nowplaying", "help"].includes(command.name) && message.member?.voice.channel !== message.guild?.me?.voice.channel - ); - } + ); + } - main(message: Message): void { - message.channel.send({ - embeds: [new Notification("Join my voice channel!")], - }); - } + main(message: Message): void { + message.channel.send({ + embeds: [new Notification("Join my voice channel!")], + }); + } }