From 1b3c1c89095ab3a6b1c4ea281d3b9833964d36b1 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Fri, 22 Mar 2024 13:45:40 -0400 Subject: [PATCH] Clean up code --- commands/games-sp/guess-song.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/commands/games-sp/guess-song.js b/commands/games-sp/guess-song.js index 533c5fb4..eebfe7c0 100644 --- a/commands/games-sp/guess-song.js +++ b/commands/games-sp/guess-song.js @@ -116,7 +116,7 @@ module.exports = class GuessSongCommand extends Command { const result = { id, name: body.name, - shortName: await this.shortTrackName(body.name), + shortName: body.name.replace(demaster, ''), artist: list(body.artists.map(artist => artist.name)), preview: previewURL }; @@ -131,10 +131,6 @@ module.exports = class GuessSongCommand extends Command { return body.props.pageProps.state.data.entity.audioPreview.url; } - shortTrackName(longName) { - return longName.replace(demaster, ''); - } - async fetchToken() { const { body } = await request .post('https://accounts.spotify.com/api/token')