From 966d578b47f4999ba0f8db874bf927e5f4246d7f Mon Sep 17 00:00:00 2001 From: Dannon Baker Date: Tue, 14 Feb 2017 15:10:02 -0500 Subject: [PATCH] Slightly more defensive programming -- we don't expose this in the UI unless there *is* a trans.user, but we might as well be careful here. --- lib/galaxy/webapps/galaxy/controllers/user.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/galaxy/webapps/galaxy/controllers/user.py b/lib/galaxy/webapps/galaxy/controllers/user.py index f28b9c00d22..c69eb8765e0 100644 --- a/lib/galaxy/webapps/galaxy/controllers/user.py +++ b/lib/galaxy/webapps/galaxy/controllers/user.py @@ -625,7 +625,8 @@ class User( BaseUIController, UsesFormDefinitionsMixin, CreatesUsersMixin, Creat else: refresh_frames = [ 'masthead', 'history' ] # Recalculate user disk usage. - trans.user.calculate_disk_usage() + if trans.user: + trans.user.calculate_disk_usage() # Since logging an event requires a session, we'll log prior to ending the session trans.log_event( "User logged out" ) else: