Signout after user disconnects on Flask
10:16 21 Mar 2018

For those of you who have used flask-login will know the decorator fresh_login_required. I am trying to implement something similar by myself.

It doesn't have to be a decorator. I just want to be able to do some works after the user has been totally disconnected (example: closed the browser). And is it a good idea to have a global integer variable to count the total active/online users?

Thanks in advance :)

python flask flask-login