diff --git a/package.json b/package.json index f6e6864..346beb2 100644 --- a/package.json +++ b/package.json @@ -29,6 +29,7 @@ }, "homepage": "https://github.com/Androz2091/discord-player#readme", "dependencies": { + "@types/node": "^14.14.7", "discord-ytdl-core": "^4.1.3", "merge-options": "^2.0.0", "moment": "^2.27.0", diff --git a/src/Player.js b/src/Player.js index cc61715..a106773 100644 --- a/src/Player.js +++ b/src/Player.js @@ -319,9 +319,9 @@ class Player extends EventEmitter { } /** - * Play a track in the server. Supported query types are `keywords`, YouTube video links`, `YouTube playlists links`, Spotify track link` or `SoundCloud song link`. - * @param {Discord.Message} message - * @param {String} query + * Play a track in the server. Supported query types are `keywords`, `YouTube video links`, `YouTube playlists links`, `Spotify track link` or `SoundCloud song link`. + * @param {Discord.Message} message Discord `message` + * @param {String|Track} query Search query or a valid `Track` object. * @returns {Promise} * * @example diff --git a/typings/index.d.ts b/typings/index.d.ts index aee6fb0..6dbf463 100644 --- a/typings/index.d.ts +++ b/typings/index.d.ts @@ -25,7 +25,7 @@ declare module 'discord-player' { public isPlaying(message: Message): boolean; public setFilters(message: Message, newFilters: Partial): Promise; - public play(message: Message, query: string): Promise; + public play(message: Message, query: string | Track): Promise; public pause(message: Message): void; public resume(message: Message): void; public stop(message: Message): void;