Araeynn commited on
Commit
6522dd8
1 Parent(s): d4a08fd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -0
app.py CHANGED
@@ -127,6 +127,11 @@ async def on_message(message:discord.Message):
127
  )
128
  with open(f"data/{message.guild.name}/{message.channel.name}", "r") as f:
129
  context = f.read()
 
 
 
 
 
130
  if message.author.id in bannedUsers:
131
  return 0
132
  if (str(message.channel.id) in o.split("\n")) or (message.channel.name == "Direct"):
 
127
  )
128
  with open(f"data/{message.guild.name}/{message.channel.name}", "r") as f:
129
  context = f.read()
130
+ try:
131
+ with open(f"{ctx.guild.name}.guild", "r") as f:
132
+ o = f.read()
133
+ except:
134
+ o = ""
135
  if message.author.id in bannedUsers:
136
  return 0
137
  if (str(message.channel.id) in o.split("\n")) or (message.channel.name == "Direct"):