Skip to content

Commit

Permalink
fix syntax error
Browse files Browse the repository at this point in the history
  • Loading branch information
sgrtye committed Jan 6, 2025
1 parent 63aa149 commit 83d1c0b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apiserver/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,14 +151,14 @@ def bytes_to_speed(bytes: int, decimal_place: int = 2) -> str:


async def xui_login() -> None:
global xui_rate_limit_time
# Rate limit to every 5 seconds
if time.time() - xui_rate_limit_time < 5:
return

await xui_session.post(
XUI_URL + "/login", data={"username": XUI_USERNAME, "password": XUI_PASSWORD}
)
global xui_rate_limit_time
xui_rate_limit_time = time.time()


Expand Down

0 comments on commit 83d1c0b

Please sign in to comment.