mirror of
https://github.com/Xevion/linkpulse.git
synced 2025-12-07 05:15:36 -06:00
Minor documentation improvement in utilities.py
This commit is contained in:
@@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
- `__main__.py`
|
||||
- `logging.py`
|
||||
- `models.py`
|
||||
- `utilities.py`
|
||||
- A `get_db` utility function to retrieve a reference to the database (with type hinting)
|
||||
- Minor `DATABASE_URL` check in `models.py` to prevent cryptic connection issues
|
||||
|
||||
|
||||
@@ -1,8 +1,14 @@
|
||||
"""utilities.py
|
||||
This module provides utility functions for database connection, string manipulation, and IP address handling.
|
||||
"""
|
||||
|
||||
import os
|
||||
from typing import Optional
|
||||
|
||||
from fastapi import Request
|
||||
from peewee import PostgresqlDatabase
|
||||
|
||||
# globally referenced
|
||||
is_development = os.getenv("ENVIRONMENT") == "development"
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user