mirror of
https://github.com/darksaid98/cadence-discord-bot.git
synced 2026-12-04 14:38:49 +00:00
fix: now showing icon for source in /nowplaying
This commit is contained in:
1 parent
52ef374be3
commit
a554551022
1 file changed
+11
-1
+11
-1
@@ -59,6 +59,14 @@ module.exports = {
|
|||||||
['arbitrary', 'Direct source']
|
['arbitrary', 'Direct source']
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
const sourceIcons = new Map([
|
||||||
|
['youtube', embedIcons.sourceYouTube],
|
||||||
|
['soundcloud', embedIcons.sourceSoundCloud],
|
||||||
|
['spotify', embedIcons.sourceSpotify],
|
||||||
|
['apple_music', embedIcons.sourceAppleMusic],
|
||||||
|
['arbitrary', embedIcons.sourceArbitrary]
|
||||||
|
]);
|
||||||
|
|
||||||
const currentTrack = queue.currentTrack;
|
const currentTrack = queue.currentTrack;
|
||||||
|
|
||||||
let author = currentTrack.author ? currentTrack.author : 'Unavailable';
|
let author = currentTrack.author ? currentTrack.author : 'Unavailable';
|
||||||
@@ -157,7 +165,9 @@ module.exports = {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: '**Audio source**',
|
name: '**Audio source**',
|
||||||
value: `**[${source}](${currentTrack.url})**`,
|
value: `**${sourceIcons.get(
|
||||||
|
currentTrack.raw.source
|
||||||
|
)} [${source}](${currentTrack.url})**`,
|
||||||
inline: true
|
inline: true
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in new issue
Block a user