merge master

This commit is contained in:
Snowflake107 2021-06-22 22:20:12 +05:45
commit f5c4ea6e86
8 changed files with 4944 additions and 15 deletions

View file

@ -1,6 +1,10 @@
--- ---
name: Bug report name: Bug report
about: Create a bug report to help us improve about: Create a bug report to help us improve
<<<<<<< HEAD
=======
title: ""
>>>>>>> 082780cce26bbec4d1069359763b96ac619fd7ce
labels: bug labels: bug
assignees: '' assignees: ''

View file

@ -1,6 +1,10 @@
--- ---
name: Feature request name: Feature request
about: Suggest an idea for this project about: Suggest an idea for this project
<<<<<<< HEAD
=======
title: ""
>>>>>>> 082780cce26bbec4d1069359763b96ac619fd7ce
labels: enhancement labels: enhancement
assignees: '' assignees: ''

View file

@ -1,6 +1,10 @@
--- ---
name: Question name: Question
about: Some questions related to this lib about: Some questions related to this lib
<<<<<<< HEAD
=======
title: ""
>>>>>>> 082780cce26bbec4d1069359763b96ac619fd7ce
labels: question labels: question
assignees: '' assignees: ''

View file

@ -140,7 +140,7 @@ class Player extends EventEmitter<PlayerEvents> {
try { try {
prev.destroy(); prev.destroy();
} catch {} // eslint-disable-line no-empty } catch { } // eslint-disable-line no-empty
this.queues.delete(guild.id); this.queues.delete(guild.id);
return prev; return prev;
@ -171,9 +171,9 @@ class Player extends EventEmitter<PlayerEvents> {
const playlist = !data.playlist const playlist = !data.playlist
? null ? null
: new Playlist(this, { : new Playlist(this, {
...data.playlist, ...data.playlist,
tracks: [] tracks: []
}); });
const tracks = data.data.map( const tracks = data.data.map(
(m) => (m) =>
@ -279,13 +279,13 @@ class Player extends EventEmitter<PlayerEvents> {
author: author:
spotifyPlaylist.type !== "playlist" spotifyPlaylist.type !== "playlist"
? { ? {
name: spotifyPlaylist.artists[0]?.name ?? "Unknown Artist", name: spotifyPlaylist.artists[0]?.name ?? "Unknown Artist",
url: spotifyPlaylist.artists[0]?.external_urls?.spotify ?? null url: spotifyPlaylist.artists[0]?.external_urls?.spotify ?? null
} }
: { : {
name: spotifyPlaylist.owner?.display_name ?? spotifyPlaylist.owner?.id ?? "Unknown Artist", name: spotifyPlaylist.owner?.display_name ?? spotifyPlaylist.owner?.id ?? "Unknown Artist",
url: spotifyPlaylist.owner?.external_urls?.spotify ?? null url: spotifyPlaylist.owner?.external_urls?.spotify ?? null
}, },
tracks: [], tracks: [],
id: spotifyPlaylist.id, id: spotifyPlaylist.id,
url: spotifyPlaylist.external_urls?.spotify ?? query, url: spotifyPlaylist.external_urls?.spotify ?? query,
@ -469,4 +469,4 @@ class Player extends EventEmitter<PlayerEvents> {
} }
} }
export { Player }; export { Player };

View file

@ -453,4 +453,4 @@ export interface PlaylistJSON {
export interface DiscordPlayerInitOptions { export interface DiscordPlayerInitOptions {
autoRegisterExtractor?: boolean; autoRegisterExtractor?: boolean;
ytdlOptions?: downloadOptions; ytdlOptions?: downloadOptions;
} }

View file

@ -113,4 +113,4 @@ const FilterList = {
}; };
export default FilterList; export default FilterList;
export { FilterList as AudioFilters }; export { FilterList as AudioFilters };

View file

@ -96,8 +96,8 @@ class Util {
} }
static get noop() { static get noop() {
return () => {}; // eslint-disable-line @typescript-eslint/no-empty-function return () => { }; // eslint-disable-line @typescript-eslint/no-empty-function
} }
} }
export { Util }; export { Util };

4917
yarn.lock Normal file

File diff suppressed because it is too large Load diff