mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 21:04:40 +01:00
20 lines
486 B
Python
20 lines
486 B
Python
CHILD_OFFSET = 15
|
|
BTN_FIXED_SIZE = 20
|
|
|
|
|
|
def is_password_required():
|
|
from openpype.settings import (
|
|
get_system_settings,
|
|
get_local_settings
|
|
)
|
|
|
|
system_settings = get_system_settings()
|
|
password = system_settings["general"].get("admin_password")
|
|
if not password:
|
|
return False
|
|
|
|
local_settings = get_local_settings()
|
|
is_admin = local_settings.get("general", {}).get("is_admin", False)
|
|
if is_admin:
|
|
return False
|
|
return True
|