Skip to content
This repository has been archived by the owner on Dec 21, 2023. It is now read-only.

Commit

Permalink
FIXED 2X LOOOOOL
Browse files Browse the repository at this point in the history
  • Loading branch information
mmattbtw committed Jul 28, 2021
1 parent 19e9f2a commit f722e5b
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions bot.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,11 @@ async def unblacklist_command(self, ctx, *, song_uri: str):

song_uri = song_uri.replace("spotify:track:", "")

if re.match(URL_REGEX, song_uri):
data = sp.track(song_uri)
song_uri = data['uri']
song_uri = song_uri.replace("spotify:track:", "")

if song_uri in jscon["blacklist"]:
jscon["blacklist"].remove(song_uri)
self.write_json(jscon, "blacklist")
Expand Down

0 comments on commit f722e5b

Please sign in to comment.