MCPcopy Index your code
hub / github.com/pgadmin-org/pgadmin4 / current_user_cleanup

Function current_user_cleanup

web/pgadmin/__init__.py:765–780  ·  view source on GitHub ↗
(app, user)

Source from the content-addressed store, hash-verified

763
764 @user_logged_out.connect_via(app)
765 def current_user_cleanup(app, user):
766 from config import PG_DEFAULT_DRIVER
767 from pgadmin.utils.driver import get_driver
768 from flask import current_app
769
770 for mdl in current_app.logout_hooks:
771 try:
772 mdl.on_logout()
773 except Exception as e:
774 current_app.logger.exception(e)
775
776 _driver = get_driver(PG_DEFAULT_DRIVER)
777 _driver.gc_own()
778
779 # remove key
780 current_app.keyManager.reset()
781
782 ##########################################################################
783 # Load plugin modules

Callers

nothing calls this directly

Calls 4

get_driverFunction · 0.90
gc_ownMethod · 0.80
on_logoutMethod · 0.45
resetMethod · 0.45

Tested by

no test coverage detected