Skip to content

Commit

Permalink
Error Fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
TEZZ444 authored Feb 27, 2024
1 parent b6dc8e0 commit a5e68cf
Showing 1 changed file with 3 additions and 10 deletions.
13 changes: 3 additions & 10 deletions src/handlers/Dispatcher.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@ import Functions from "./../Struct/functions.js";
*/
export default async (client) => {
client.kazagumo.on("playerStart", async (player, track) => {
track.requester = player.previous
? player.queue.previous.requester
: player.queue.current.requester;
track.requester = player.queue.current.requester;
if (track.uri.includes("https://cdn.discordapp.com/attachments/")) {
return;
}
Expand Down Expand Up @@ -49,9 +47,7 @@ export default async (client) => {
const embed = new EmbedBuilder()
.setAuthor({
name: `Now Playing`,
iconURL: player.queue.previous
? player.queue.previous.requester.displayAvatarURL({ dynamic: true })
: player.queue.current.requester.displayAvatarURL({ dynamic: true }),
iconURL: player.queue.current.requester.displayAvatarURL({ dynamic: true }),
})
.setColor(client.settings.COLOR)
.setDescription(
Expand All @@ -65,10 +61,7 @@ export default async (client) => {
.addFields(
{
name: `Requester`,
value: `[${
player.queue.previous
? player.queue.previous.requester.username
: player.queue.current.requester.username
value: `[${player.queue.current.requester.globalName
}](https://discord.gg/fuZBHxzDNc)`,
inline: true,
},
Expand Down

0 comments on commit a5e68cf

Please sign in to comment.