Report error for request search

This commit is contained in:
dsc 2021-06-17 04:11:14 +02:00
parent b4fbe65002
commit 6302eb858f

View File

@ -121,7 +121,10 @@ class Commands:
send_message(target=target, message="usage: !request <id>") send_message(target=target, message="usage: !request <id>")
needle = " ".join(args) needle = " ".join(args)
songs = Song.search(needle) try:
songs = Song.search(needle)
except Exception as ex:
return await send_message(target, f"{ex}")
if not songs: if not songs:
return await send_message(target, "Not found!") return await send_message(target, "Not found!")