We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 07b359c commit 6ba25f3Copy full SHA for 6ba25f3
1 file changed
siegeapi/auth.py
@@ -152,13 +152,15 @@ def load_creds(self) -> None:
152
self.expiration = data.get("expiration", "")
153
self.new_expiration = data.get("new_expiration", "")
154
155
+ self._login_cooldown = 0
156
+
157
async def connect(self, _new: bool = False) -> None:
158
""" Connect to Ubisoft, automatically called when needed """
159
+ self.load_creds()
160
161
if self._login_cooldown > time.time():
162
raise FailedToConnect("Login on cooldown")
163
- self.load_creds()
-
164
# If keys are still valid, don't connect again
165
if _new:
166
if self.new_key and datetime.fromisoformat(self.new_expiration[:26]+"+00:00") > datetime.now(timezone.utc):
0 commit comments