You've already forked hotpocket
This commit is contained in:
11
services/backend/hotpocket_backend/apps/accounts/checks.py
Normal file
11
services/backend/hotpocket_backend/apps/accounts/checks.py
Normal file
@@ -0,0 +1,11 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import annotations
|
||||
|
||||
from hotpocket_backend.apps.accounts.types import PAccount
|
||||
|
||||
|
||||
def is_authenticated_and_active_account(account: PAccount) -> bool:
|
||||
return all((
|
||||
account.is_authenticated,
|
||||
account.is_active,
|
||||
))
|
||||
Reference in New Issue
Block a user