check permission fixes
This commit is contained in:
parent
2f9337161d
commit
9390d56404
6
main.py
6
main.py
@ -16,11 +16,9 @@ bot = telebot.TeleBot(config.bot_token)
|
|||||||
#telebot.logger.setLevel(logging.DEBUG)
|
#telebot.logger.setLevel(logging.DEBUG)
|
||||||
|
|
||||||
def check_permission(uid):
|
def check_permission(uid):
|
||||||
user = str(uid)
|
if uid not in config.users:
|
||||||
for userid in config.users:
|
|
||||||
if userid == user:
|
|
||||||
return True
|
|
||||||
return False
|
return False
|
||||||
|
return True
|
||||||
|
|
||||||
def file_ext(filename):
|
def file_ext(filename):
|
||||||
return filename.split(".")[-1]
|
return filename.split(".")[-1]
|
||||||
|
Loading…
Reference in New Issue
Block a user