Skip to content

Commit

Permalink
Cache default profile picture
Browse files Browse the repository at this point in the history
  • Loading branch information
cyrillkuettel committed Aug 5, 2024
1 parent 10d2ff7 commit ba0d4f3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/privatim/models/profile_pic.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
from privatim.static import get_default_profile_pic_data
from functools import cache
from sqlalchemy import select


Expand All @@ -8,6 +9,7 @@
from privatim.models import GeneralFile


@cache
def get_or_create_default_profile_pic(session: 'Session') -> 'GeneralFile':
from privatim.models import GeneralFile
stmt = select(GeneralFile).where(
Expand Down

0 comments on commit ba0d4f3

Please sign in to comment.