sing - minor, respond with actual API error on failure, rather than just always "Not found!"
This commit is contained in:
parent
6e74c1bb31
commit
11ff1d6447
@ -78,7 +78,9 @@ class Sing(commands.Cog):
|
||||
return
|
||||
|
||||
if len(search_result) == 1:
|
||||
return await ctx.respond("ERR: Not found!")
|
||||
# Error response from API
|
||||
error, *_ = search_result[0]
|
||||
return await ctx.respond(error)
|
||||
if not isinstance(search_result[0], tuple):
|
||||
return # Invalid data type
|
||||
(
|
||||
|
Loading…
x
Reference in New Issue
Block a user