Skip to content

Commit

Permalink
Return set_max_ping_autokick result as a bool and not str
Browse files Browse the repository at this point in the history
  • Loading branch information
cemathey committed May 22, 2024
1 parent 0a6d9b0 commit 8f42a99
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions rcon/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -540,8 +540,8 @@ def set_map_shuffle_enabled(self, enabled: bool) -> None:
def set_idle_autokick_time(self, minutes) -> bool:
return self._str_request(f"setkickidletime {minutes}", log_info=True) == SUCCESS

def set_max_ping_autokick(self, max_ms) -> str:
return self._str_request(f"sethighping {max_ms}", log_info=True)
def set_max_ping_autokick(self, max_ms) -> bool:
return self._str_request(f"sethighping {max_ms}", log_info=True) == SUCCESS

def set_autobalance_threshold(self, max_diff: int):
return (
Expand Down
2 changes: 1 addition & 1 deletion rcon/rcon.py
Original file line number Diff line number Diff line change
Expand Up @@ -914,7 +914,7 @@ def set_idle_autokick_time(self, minutes) -> bool:
def get_max_ping_autokick(self) -> int:
return int(super().get_max_ping_autokick())

def set_max_ping_autokick(self, max_ms) -> str:
def set_max_ping_autokick(self, max_ms) -> bool:
with invalidates(Rcon.get_max_ping_autokick):
return super().set_max_ping_autokick(max_ms)

Expand Down

0 comments on commit 8f42a99

Please sign in to comment.