Update dependencies and fix a reminder bug #102
7 changed files with 565 additions and 487 deletions
1012
package-lock.json
generated
1012
package-lock.json
generated
File diff suppressed because it is too large
Load diff
21
package.json
21
package.json
|
@ -16,27 +16,24 @@
|
|||
"author": "La confrérie du Kassoulait",
|
||||
"license": "GPL-3.0-only",
|
||||
"dependencies": {
|
||||
"@discord-player/extractor": "^4.2.1",
|
||||
"@discord-player/extractor": "^4.4.1",
|
||||
"@discordjs/opus": "^0.9.0",
|
||||
"@discordjs/rest": "^1.7.0",
|
||||
"@discordjs/rest": "^2.0.0",
|
||||
"@types/sqlite3": "^3.1.8",
|
||||
"@types/uuid": "^9.0.1",
|
||||
"discord-player": "^6.2.1",
|
||||
"discord.js": "^14.9.0",
|
||||
"@types/uuid": "^9.0.2",
|
||||
"discord-player": "^6.6.2",
|
||||
"discord.js": "^14.12.1",
|
||||
"genius-lyrics": "^4.4.3",
|
||||
"node-fetch": "^2.6.9",
|
||||
"play-dl": "^1.9.6",
|
||||
"sqlite3": "^5.1.6",
|
||||
"typescript": "^5.0.4",
|
||||
"typescript": "^5.1.6",
|
||||
"uuid": "^9.0.0"
|
||||
},
|
||||
"overrides": {
|
||||
"discord-api-types": "0.37.34"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@typescript-eslint/eslint-plugin": "^5.30.7",
|
||||
"@typescript-eslint/parser": "^5.30.7",
|
||||
"dotenv": "^16.0.1",
|
||||
"@typescript-eslint/eslint-plugin": "^6.2.1",
|
||||
"@typescript-eslint/parser": "^6.2.1",
|
||||
"dotenv": "^16.3.1",
|
||||
"prettier-eslint": "^15.0.1",
|
||||
"ts-node-dev": "^2.0.0"
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import { SlashCommandBuilder } from "@discordjs/builders";
|
||||
import { Player, useMasterPlayer, useQueue } from "discord-player";
|
||||
import { Player, useMainPlayer, useQueue } from "discord-player";
|
||||
import { ChatInputCommandInteraction, Client, EmbedBuilder } from "discord.js";
|
||||
import { getLocale, getLocalizations } from "../../utils/locales";
|
||||
import { getFilename } from "../../utils/misc";
|
||||
|
@ -45,7 +45,7 @@ export default {
|
|||
let data = null;
|
||||
await interaction.deferReply();
|
||||
|
||||
const player = useMasterPlayer() as Player;
|
||||
const player = useMainPlayer() as Player;
|
||||
if (request) {
|
||||
try {
|
||||
data = await player.lyrics.search(request);
|
||||
|
|
|
@ -10,7 +10,7 @@ import {
|
|||
import { Metadata } from "../../utils/metadata";
|
||||
import { getLocale, getLocalizations } from "../../utils/locales";
|
||||
import { getFilename } from "../../utils/misc";
|
||||
import { Player, QueryType, SearchResult, useMasterPlayer, useQueue } from "discord-player";
|
||||
import { Player, QueryType, SearchResult, useMainPlayer, useQueue } from "discord-player";
|
||||
|
||||
export default {
|
||||
scope: () => [],
|
||||
|
@ -71,7 +71,7 @@ export default {
|
|||
loc_default?.get(`c_${filename}_opt1_name`) as string
|
||||
);
|
||||
|
||||
const player = useMasterPlayer() as Player;
|
||||
const player = useMainPlayer() as Player;
|
||||
if (!query) {
|
||||
// Now playing
|
||||
|
||||
|
@ -154,7 +154,7 @@ export default {
|
|||
const loc_default = interaction.client.locales.get(interaction.client.config.default_lang);
|
||||
const filename = getFilename(__filename);
|
||||
|
||||
const player = useMasterPlayer() as Player;
|
||||
const player = useMainPlayer() as Player;
|
||||
const query = interaction.options.getString(
|
||||
loc_default?.get(`c_${filename}_opt1_name`) as string,
|
||||
true
|
||||
|
|
|
@ -3,7 +3,7 @@ import { ChatInputCommandInteraction, Client, GuildResolvable } from "discord.js
|
|||
import { Metadata } from "../../utils/metadata";
|
||||
import { getLocale, getLocalizations } from "../../utils/locales";
|
||||
import { getFilename } from "../../utils/misc";
|
||||
import { Player, useMasterPlayer } from "discord-player";
|
||||
import { Player, useMainPlayer } from "discord-player";
|
||||
|
||||
export default {
|
||||
scope: () => [],
|
||||
|
@ -25,7 +25,7 @@ export default {
|
|||
interaction: async (interaction: ChatInputCommandInteraction, client: Client) => {
|
||||
const loc = getLocale(client, interaction.locale);
|
||||
|
||||
const player = useMasterPlayer() as Player;
|
||||
const player = useMainPlayer() as Player;
|
||||
const queue = player.nodes.create(interaction.guild as GuildResolvable, {
|
||||
metadata: {
|
||||
channel: interaction.channel,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import { Player, PlayerEvents, useMasterPlayer } from "discord-player";
|
||||
import { Player, PlayerEvents, useMainPlayer } from "discord-player";
|
||||
import { Client } from "discord.js";
|
||||
import { readdir } from "fs/promises";
|
||||
|
||||
|
@ -29,7 +29,7 @@ export default async (client: Client) => {
|
|||
const event_type = event_type_ext.join(".");
|
||||
|
||||
if (event_category == "player") {
|
||||
const player = useMasterPlayer() as Player;
|
||||
const player = useMainPlayer() as Player;
|
||||
if (once) {
|
||||
// eslint-disable-next-line
|
||||
return player.events.once(event_type as keyof PlayerEvents, (...args: any[]) => {
|
||||
|
|
|
@ -39,7 +39,6 @@ export default async () => {
|
|||
};
|
||||
|
||||
const player = Player.singleton(client, {
|
||||
autoRegisterExtractor: false,
|
||||
ytdlOptions: {
|
||||
filter: "audioonly",
|
||||
quality: "highestaudio",
|
||||
|
|
Loading…
Reference in a new issue