v8.1.2: Change get_user_status to select_user_status

Renamed get_user_status to select_user_status in roxy.py and db.py for better clarity and consistency. This modification ensures alignment in method naming conventions across the codebase, improving readability and maintainability.
pull/401/head
Aidaho 2024-11-04 19:54:27 +03:00
parent 61ed3e92c3
commit 3d642a61c4
2 changed files with 2 additions and 2 deletions

View File

@ -33,7 +33,7 @@ def get_user() -> UserName:
print(str(e))
def get_user_status() -> int:
def select_user_status() -> int:
try:
return UserName.get().Status
except Exception:

View File

@ -101,7 +101,7 @@ def action_service(action: str, service: str) -> str:
'restart': 'restart',
}
cmd = f"sudo systemctl {actions[action]} {service}"
if not roxy_sql.get_user_status():
if not roxy_sql.select_user_status():
return 'warning: The service is disabled because you are not subscribed. Read <a href="https://roxy-wi.org/pricing" ' \
'title="Roxy-WI pricing" target="_blank">here</a> about subscriptions'
if is_in_docker: