HA! UPDATES!!
This commit is contained in:
parent
a56e20d43d
commit
9ce7ff659b
5
bot.py
5
bot.py
|
@ -40,11 +40,12 @@ groups = []
|
|||
try:
|
||||
with open(f'{CURR_DIR}/groupsin.txt', 'r') as e:
|
||||
groups = [groups.append(group.replace('\n', '')) for group in e]
|
||||
print(groups)
|
||||
print(f'The bot is running in {len(groups)} groups.')
|
||||
|
||||
except FileNotFoundError:
|
||||
# creating a plain text file for further use
|
||||
with open('groupsin.txt', 'a+'):
|
||||
with open('groupsin.txt', 'w') as f:
|
||||
print('groupsin.txt file created in order to work properly')
|
||||
pass
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue