Update add_user.py
This commit is contained in:
parent
d1fcd4e97a
commit
d4bfbc841e
|
@ -17,7 +17,7 @@ def add_user(users_list=None):
|
||||||
users_list = Path(users_list) if users_list else Path('authorized_users.txt')
|
users_list = Path(users_list) if users_list else Path('authorized_users.txt')
|
||||||
users_list.touch(exist_ok=True)
|
users_list.touch(exist_ok=True)
|
||||||
with open(users_list, 'a') as f:
|
with open(users_list, 'a') as f:
|
||||||
f.write(f'{user_name},{key}\n')
|
f.write(f'{user_name}:{key}\n')
|
||||||
print(f'User {user_name} added to the authorized users list')
|
print(f'User {user_name} added to the authorized users list')
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
Loading…
Reference in New Issue