1
0
Fork 0
mirror of https://gitlab.com/oloturia/fumcaso.git synced 2025-01-06 21:47:17 +01:00

fixed file not closed

This commit is contained in:
oloturia 2021-05-27 16:06:15 +02:00
parent 43fa7d6992
commit 9ebd2a8748

View file

@ -12,7 +12,9 @@ def newStrip(bot, update, args):
status = createStrip(config)
if status == 0:
try:
bot.send_photo(chat_id=update.message.chat_id,photo=open(config["saveLocation"]+config["filename"],"rb"))
strip_file=open(config["saveLocation"]+config["filename"],"rb")
bot.send_photo(chat_id=update.message.chat_id,photo=strip_file)
strip_file.close()
except Exception as err:
print(err)
else: