Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions commons/data_access_layer/cosmos_db.py
Original file line number Diff line number Diff line change
Expand Up @@ -379,6 +379,11 @@ def __init__(self, status_code: int, description: str = None):
self.description = description


def init_app(app: Flask) -> None:
global cosmos_helper
cosmos_helper = CosmosDBFacade.from_flask_config(app)


def current_datetime() -> datetime:
return datetime.utcnow()

Expand All @@ -398,11 +403,6 @@ def generate_uuid4() -> str:
return str(uuid.uuid4())


def init_app(app: Flask) -> None:
global cosmos_helper
cosmos_helper = CosmosDBFacade.from_flask_config(app)


def get_last_day_of_month(year: int, month: int) -> int:
from calendar import monthrange
return monthrange(year=year, month=month)[1]
Expand Down
Loading