From 42b3c6ebb50ecaabf92e3d168da1be05a640f9f2 Mon Sep 17 00:00:00 2001 From: davelopez <46503462+davelopez@users.noreply.github.com> Date: Wed, 11 May 2022 16:31:46 +0200 Subject: [PATCH] Fix condition importing histories anonymously --- lib/galaxy/webapps/galaxy/api/histories.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/galaxy/webapps/galaxy/api/histories.py b/lib/galaxy/webapps/galaxy/api/histories.py index 6b57e569686..393d9d26970 100644 --- a/lib/galaxy/webapps/galaxy/api/histories.py +++ b/lib/galaxy/webapps/galaxy/api/histories.py @@ -334,7 +334,7 @@ class HistoriesController(BaseGalaxyAPIController, ExportsHistoryMixin, ImportsH :rtype: dict :returns: element view of new history """ - if trans.user.bootstrap_admin_user: + if trans.user and trans.user.bootstrap_admin_user: raise exceptions.RealUserRequiredException("Only real users can create histories.") hist_name = None if payload.get('name', None):