Record request language in uWSGI logs

This commit is contained in:
Tudor Brindus 2023-03-05 16:36:28 -05:00 committed by Guanzhong Chen
parent 1f2515515a
commit 473a77d824

View File

@ -45,6 +45,7 @@ class DMOJLoginMiddleware(object):
profile = request.profile = request.user.profile
if uwsgi:
uwsgi.set_logvar('username', request.user.username)
uwsgi.set_logvar('language', request.LANGUAGE_CODE)
logout_path = reverse('auth_logout')
login_2fa_path = reverse('login_2fa')