revert to [stable everything]
Browse files
app.py
CHANGED
@@ -84,7 +84,7 @@ async def safetychecks(ctx):
|
|
84 |
await ctx.reply(f"β
{bot} is online")
|
85 |
|
86 |
#β
β
check if the command is in the allowed channel(s)
|
87 |
-
channel_id =
|
88 |
if ctx.channel.id != channel_id: # #bot-test = 1100458786826747945
|
89 |
print(f"If using a command, commands are not permitted in {ctx.channel}")
|
90 |
return False
|
@@ -93,7 +93,7 @@ async def safetychecks(ctx):
|
|
93 |
|
94 |
#β
β
check if the user has the required role(s)
|
95 |
guild_id = 879548962464493619
|
96 |
-
required_role_id =
|
97 |
guild = bot.get_guild(guild_id)
|
98 |
required_role = guild.get_role(required_role_id)
|
99 |
if required_role not in ctx.author.roles:
|
@@ -101,7 +101,8 @@ async def safetychecks(ctx):
|
|
101 |
return False
|
102 |
else:
|
103 |
await ctx.reply(f"β
{ctx.author} has the required role {required_role}")
|
104 |
-
|
|
|
105 |
|
106 |
# ping lunarflu if any safety check ever fails
|
107 |
except Exception as e:
|
@@ -405,7 +406,7 @@ async def on_reaction_add(reaction, user): # ctx = await bot.get_context(reac
|
|
405 |
threadparentid = thread.parent.id
|
406 |
|
407 |
if not user.bot:
|
408 |
-
if threadparentid ==
|
409 |
# 811235357663297546 = lunarflu
|
410 |
if reaction.message.attachments:
|
411 |
if user.id == reaction.message.mentions[0].id: # if user.id == reaction.message.mentions[0].id:
|
|
|
84 |
await ctx.reply(f"β
{bot} is online")
|
85 |
|
86 |
#β
β
check if the command is in the allowed channel(s)
|
87 |
+
channel_id = 1100458786826747945
|
88 |
if ctx.channel.id != channel_id: # #bot-test = 1100458786826747945
|
89 |
print(f"If using a command, commands are not permitted in {ctx.channel}")
|
90 |
return False
|
|
|
93 |
|
94 |
#β
β
check if the user has the required role(s)
|
95 |
guild_id = 879548962464493619
|
96 |
+
required_role_id = 900063512829755413 # @verified = 900063512829755413, HF = 897376942817419265
|
97 |
guild = bot.get_guild(guild_id)
|
98 |
required_role = guild.get_role(required_role_id)
|
99 |
if required_role not in ctx.author.roles:
|
|
|
101 |
return False
|
102 |
else:
|
103 |
await ctx.reply(f"β
{ctx.author} has the required role {required_role}")
|
104 |
+
|
105 |
+
return True
|
106 |
|
107 |
# ping lunarflu if any safety check ever fails
|
108 |
except Exception as e:
|
|
|
406 |
threadparentid = thread.parent.id
|
407 |
|
408 |
if not user.bot:
|
409 |
+
if threadparentid == 1100458786826747945: # bot-test
|
410 |
# 811235357663297546 = lunarflu
|
411 |
if reaction.message.attachments:
|
412 |
if user.id == reaction.message.mentions[0].id: # if user.id == reaction.message.mentions[0].id:
|