mirror of
https://github.com/Paillat-dev/Botator.git
synced 2026-01-02 01:06:19 +00:00
fix(makeprompt.py): add exception handling and raise exception instead of pass
This commit is contained in:
@@ -61,7 +61,8 @@ def get_guild_data(message):
|
|||||||
curs_premium.execute(
|
curs_premium.execute(
|
||||||
"SELECT * FROM data WHERE guild_id = ?", (guid,)
|
"SELECT * FROM data WHERE guild_id = ?", (guid,)
|
||||||
) # get the data of the guild
|
) # get the data of the guild
|
||||||
except:
|
except Exception as e:
|
||||||
|
raise e
|
||||||
pass
|
pass
|
||||||
|
|
||||||
try:
|
try:
|
||||||
@@ -77,7 +78,8 @@ def get_guild_data(message):
|
|||||||
# [2] # get the premium status of the guild
|
# [2] # get the premium status of the guild
|
||||||
data = curs_premium.fetchone()
|
data = curs_premium.fetchone()
|
||||||
premium = data[2]
|
premium = data[2]
|
||||||
except:
|
except Exception as e:
|
||||||
|
raise e
|
||||||
premium = 0 # if the guild is not in the database, it's not premium
|
premium = 0 # if the guild is not in the database, it's not premium
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in New Issue
Block a user