[mod] py: cleanup link_token.py

This commit is contained in:
Ivan Gabaldon
2026-07-30 14:36:55 +02:00
committed by Bnyro
parent 98e10f9ab4
commit f25b75e613

View File

@@ -151,6 +151,6 @@ def get_token() -> str:
if token: if token:
token = token.decode('UTF-8') # type: ignore token = token.decode('UTF-8') # type: ignore
else: else:
token = ''.join(random.choice(string.ascii_lowercase + string.digits) for _ in range(16)) token = ''.join(random.choices(string.ascii_lowercase + string.digits, k=16))
valkey_client.set(TOKEN_KEY, token, ex=TOKEN_LIVE_TIME) valkey_client.set(TOKEN_KEY, token, ex=TOKEN_LIVE_TIME)
return token return token