lunarflu HF staff commited on
Commit
abcbe65
1 Parent(s): 6971a6a

fixsheets part 1

Browse files
Files changed (1) hide show
  1. app.py +24 -0
app.py CHANGED
@@ -213,6 +213,30 @@ def calculate_level(xp):
213
  return int(xp ** (1.0 / 3.0))
214
 
215
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
216
  @bot.command()
217
  async def level(ctx):
218
  if ctx.author.id == 811235357663297546:
 
213
  return int(xp ** (1.0 / 3.0))
214
 
215
 
216
+ @bot.command()
217
+ async def fixsheets(ctx):
218
+ if ctx.author.id == 811235357663297546:
219
+ try:
220
+ # iterate through @verified role members
221
+
222
+ # test in test sheet first
223
+
224
+ role_id = int(900063512829755413) # 900063512829755413 = @verified
225
+ role = discord.utils.get(ctx.guild.roles, id=role_id)
226
+
227
+ if role is None:
228
+ print(f"Role with ID '{role_id}' not found.")
229
+ return
230
+
231
+ members_with_role = [member.id for member in ctx.guild.members if role in member.roles]
232
+
233
+ print(f"Members with the role with ID '{role_id}': {', '.join(map(str, members_with_role))}")
234
+
235
+
236
+ except Exception as e:
237
+ print(f"Error: {e}")
238
+
239
+
240
  @bot.command()
241
  async def level(ctx):
242
  if ctx.author.id == 811235357663297546: