lunarflu HF staff commited on
Commit
d1d4fa9
1 Parent(s): a12522f

Synced repo using 'sync_with_huggingface' Github Action

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -50,8 +50,9 @@ async def on_message(message):
50
  if any(string.lower() in message.content.lower() for string in forbidden_strings):
51
  ignored_role_ids = [897381378172264449, 897376942817419265] #admins, huggingfolks
52
  if any(role.id in ignored_role_ids for role in message.author.roles):
53
- return
54
- dm_unwanted = await lunarflu.send(f"FORBIDDEN STRING: {message_link} |{message.author}: {message.content}")
 
55
  except Exception as e:
56
  print(f"Antispam->Detecting certain unwanted strings Error: {e}")
57
 
 
50
  if any(string.lower() in message.content.lower() for string in forbidden_strings):
51
  ignored_role_ids = [897381378172264449, 897376942817419265] #admins, huggingfolks
52
  if any(role.id in ignored_role_ids for role in message.author.roles):
53
+ if message.author != lunarflu:
54
+ return
55
+ dm_unwanted = await lunarflu.send(f" {lunarflu.mention} FORBIDDEN STRING: {message_link} |{message.author}: {message.content}")
56
  except Exception as e:
57
  print(f"Antispam->Detecting certain unwanted strings Error: {e}")
58