lunarflu HF staff commited on
Commit
311cce7
1 Parent(s): 5d8559e

remove huggingfolks for testing

Browse files
Files changed (1) hide show
  1. app.py +18 -18
app.py CHANGED
@@ -88,24 +88,24 @@ async def on_message(message):
88
 
89
  huggingfolks_role = discord.utils.get(message.guild.roles, id=897376942817419265)
90
  bots_role = discord.utils.get(message.guild.roles, id=1258328471609016341)
91
- if huggingfolks_role not in message.author.roles: # no need for ping if we're already discussing
92
- if bots_role not in message.author.roles: # bots shouldn't trigger pings for this
93
- print(" not bot ")
94
- content = message.content.lower()
95
-
96
- for trigger, slack_mention in TRIGGERS.items():
97
- if all(word in content for word in trigger):
98
- adjacent_words = extract_adjacent_words(message.content, trigger, 3)
99
- daily_pings.append({
100
- 'author': str(message.author),
101
- 'content': adjacent_words,
102
- 'channel': message.channel.name,
103
- 'url': message.jump_url,
104
- 'mention': slack_mention,
105
- 'trigger': trigger
106
- })
107
- print(f"daily pings:{daily_pings}")
108
- break
109
 
110
 
111
 
 
88
 
89
  huggingfolks_role = discord.utils.get(message.guild.roles, id=897376942817419265)
90
  bots_role = discord.utils.get(message.guild.roles, id=1258328471609016341)
91
+ #if huggingfolks_role not in message.author.roles: # no need for ping if we're already discussing
92
+ if bots_role not in message.author.roles: # bots shouldn't trigger pings for this
93
+ print(" not bot ")
94
+ content = message.content.lower()
95
+
96
+ for trigger, slack_mention in TRIGGERS.items():
97
+ if all(word in content for word in trigger):
98
+ adjacent_words = extract_adjacent_words(message.content, trigger, 3)
99
+ daily_pings.append({
100
+ 'author': str(message.author),
101
+ 'content': adjacent_words,
102
+ 'channel': message.channel.name,
103
+ 'url': message.jump_url,
104
+ 'mention': slack_mention,
105
+ 'trigger': trigger
106
+ })
107
+ print(f"daily pings:{daily_pings}")
108
+ break
109
 
110
 
111