1
0
Fork 0
forked from waifu/kemoverse
This commit is contained in:
w 2025-06-02 00:37:39 -03:00
parent 66a91b5deb
commit b7d82d9117

View file

@ -44,7 +44,7 @@ def get_player(username: str) -> int:
if user:
return int(user[0])
def insert_player(username):
def insert_player(username: str) -> int:
'''Insert a new player with default has_rolled = False and return their user ID.'''
CURSOR.execute(
'INSERT INTO users (username, has_rolled) VALUES (?, ?)',
@ -52,7 +52,7 @@ def insert_player(username):
)
return CURSOR.lastrowid
def delete_player(username):
def delete_player(username: str) -> bool:
'''Permanently deletes a user and all their pulls.'''
CURSOR.execute(
'SELECT id FROM users WHERE username = ?',