Skip to content

Commit

Permalink
Temporarily disabling a feature for testing
Browse files Browse the repository at this point in the history
  • Loading branch information
MikeyUsersREC committed Mar 10, 2024
1 parent a155e27 commit 0080fb1
Showing 1 changed file with 13 additions and 11 deletions.
24 changes: 13 additions & 11 deletions erm.py
Original file line number Diff line number Diff line change
Expand Up @@ -485,17 +485,19 @@ async def check_reminders():
item["lastTriggered"] = lastTriggered
await bot.reminders.update_by_id(new_go)

if isinstance(item.get('integration'), dict):
# This has the ERLC integration enabled
command = 'h' if item['integration']['type'] == 'Hint' else ('m' if item['integration']['type'] == 'Message' else None)
content = item['integration']['content']
total = ':' + command + ' ' + content
if await bot.server_keys.db.count_documents({'_id': channel.guild.id}) != 0:
resp = await bot.prc_api.run_command(channel.guild.id, total)
if resp[0] != 200:
print('Failed reaching PRC due to {} status code'.format(resp))
else:
print('Integration success with 200 status code')

# !! THIS IS TEMPORARILY DISABLED
# if isinstance(item.get('integration'), dict):
# # This has the ERLC integration enabled
# command = 'h' if item['integration']['type'] == 'Hint' else ('m' if item['integration']['type'] == 'Message' else None)
# content = item['integration']['content']
# total = ':' + command + ' ' + content
# if await bot.server_keys.db.count_documents({'_id': channel.guild.id}) != 0:
# resp = await bot.prc_api.run_command(channel.guild.id, total)
# if resp[0] != 200:
# print('Failed reaching PRC due to {} status code'.format(resp))
# else:
# print('Integration success with 200 status code')

if not view:
await channel.send(" ".join(roles), embed=embed,
Expand Down

0 comments on commit 0080fb1

Please sign in to comment.