Answer the question
In order to leave comments, you need to log in
Where to override the method returning the logged in user?
In the application, user session data is stored in the database, several custom classes were written for this logic before me.
Previously, when a user logged out or someone logged in from another device, the corresponding document was simply deleted from the database, and when the page was reloaded, the user was redirected to the login page.
At the moment, documents are not deleted, but the value is added to them active=False
, respectively, when logging in from another device, the first user supposedly remains logged in anyway.
What method is responsible for checking the existence of session data in the database so that the application behaves as before, only looking not at the existence of the document, but at its parameter active
? Can anyone come across?
I guess it might be indjango.contrib.sessions.backends.base.SessionBase
I will experiment.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question