From 2d63b24c8fb34d02ff398ad635baa7a6528e94b8 Mon Sep 17 00:00:00 2001 From: DevilXD Date: Thu, 16 Dec 2021 14:18:30 +0100 Subject: [PATCH] Fix user_id being a str instead of int --- twitch.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/twitch.py b/twitch.py index 4127901..8776935 100644 --- a/twitch.py +++ b/twitch.py @@ -403,7 +403,8 @@ class Twitch: elif status == 200: validate_response = await response.json() break - self._user_id = cookie["persistent"] = validate_response["user_id"] + self._user_id = int(validate_response["user_id"]) + cookie["persistent"] = str(self._user_id) self._is_logged_in.set() print(f"Login successful, User ID: {self._user_id}") # update our cookie and save it