mirror of
https://github.com/grillazz/fastapi-sqlalchemy-asyncpg.git
synced 2025-11-30 13:20:40 +03:00
drop redundant lru cache
This commit is contained in:
@@ -1,5 +1,4 @@
|
|||||||
import os
|
import os
|
||||||
from functools import lru_cache
|
|
||||||
|
|
||||||
from pydantic import PostgresDsn, RedisDsn
|
from pydantic import PostgresDsn, RedisDsn
|
||||||
from pydantic_settings import BaseSettings
|
from pydantic_settings import BaseSettings
|
||||||
@@ -12,9 +11,4 @@ class Settings(BaseSettings):
|
|||||||
jwt_expire: int = os.getenv("JWT_EXPIRE")
|
jwt_expire: int = os.getenv("JWT_EXPIRE")
|
||||||
|
|
||||||
|
|
||||||
@lru_cache
|
settings = Settings()
|
||||||
def get_settings():
|
|
||||||
return Settings()
|
|
||||||
|
|
||||||
|
|
||||||
settings = get_settings()
|
|
||||||
|
|||||||
Reference in New Issue
Block a user