parent
35f99c849f
commit
fa664e6663
|
|
@ -5,7 +5,9 @@ import threading
|
||||||
from telegram.ext import Updater
|
from telegram.ext import Updater
|
||||||
import os
|
import os
|
||||||
|
|
||||||
with open('log.txt', 'r+') as f:
|
|
||||||
|
if os.path.exists('log.txt'):
|
||||||
|
with open('log.txt', 'r+') as f:
|
||||||
f.truncate(0)
|
f.truncate(0)
|
||||||
|
|
||||||
logging.basicConfig(format='%(asctime)s - %(name)s - %(levelname)s - %(message)s',
|
logging.basicConfig(format='%(asctime)s - %(name)s - %(levelname)s - %(message)s',
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue