Skip to content

Commit 3f61a54

Browse files
committed
Remove URI/URL from spotify URL regex hook to avoid duplication
1 parent 74c9c76 commit 3f61a54

1 file changed

Lines changed: 2 additions & 7 deletions

File tree

plugins/spotify.py

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -131,16 +131,11 @@ def spotify_url(bot, match):
131131
name = data["name"]
132132
artist = data["artists"][0]["name"]
133133
album = data["album"]["name"]
134-
url = data['external_urls']['spotify']
135-
uri = data['uri']
136134

137-
return "Spotify Track: \x02{}\x02 by \x02{}\x02 from the album \x02{}\x02 {} [{}]".format(
138-
name, artist, album, url, uri)
135+
return "Spotify Track: \x02{}\x02 by \x02{}\x02 from the album \x02{}\x02".format(name, artist, album)
139136
elif _type == "artist":
140137
return "Spotify Artist: \x02{}\x02, followers: \x02{}\x02, genres: \x02{}\x02".format(
141138
data["name"], data["followers"]["total"],
142139
', '.join(data["genres"]))
143140
elif _type == "album":
144-
return "Spotify Album: \x02{}\x02 - \x02{}\x02 {} [{}]".format(
145-
data["artists"][0]["name"], data["name"],
146-
data['external_urls']['spotify'], data['uri'])
141+
return "Spotify Album: \x02{}\x02 - \x02{}\x02".format(data["artists"][0]["name"], data["name"])

0 commit comments

Comments
 (0)