Files
marriage_frontend/ui/context_processors.py
2025-08-10 15:31:47 +09:00

12 lines
285 B
Python

from django.conf import settings
def public_settings(request):
return {
'DEBUG': settings.DEBUG,
}
def current_user(request):
# Very lightweight 'user' from API token in session
auth = request.session.get('auth', {})
return {'api_user': auth.get('user')}