snapshot: preserve trial lifecycle and product-grade expiry UX
This commit is contained in:
@@ -5,6 +5,7 @@ import time
|
||||
import requests
|
||||
from django.conf import settings
|
||||
|
||||
from .branding import should_restrict_trial_integrations
|
||||
from .models import WorkflowConfig
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
@@ -15,6 +16,8 @@ def _active_workflow_config() -> WorkflowConfig | None:
|
||||
|
||||
|
||||
def is_nextcloud_enabled() -> bool:
|
||||
if should_restrict_trial_integrations():
|
||||
return False
|
||||
config = _active_workflow_config()
|
||||
if config and config.nextcloud_enabled_override is not None:
|
||||
return bool(config.nextcloud_enabled_override)
|
||||
@@ -22,6 +25,8 @@ def is_nextcloud_enabled() -> bool:
|
||||
|
||||
|
||||
def is_email_test_mode() -> bool:
|
||||
if should_restrict_trial_integrations():
|
||||
return True
|
||||
config = _active_workflow_config()
|
||||
if config and config.email_test_mode_override is not None:
|
||||
return bool(config.email_test_mode_override)
|
||||
|
||||
Reference in New Issue
Block a user