From 85c8583145127da94469e244faa5859c5546153a Mon Sep 17 00:00:00 2001 From: Alan Davis Date: Fri, 16 May 2014 20:10:47 +0000 Subject: [PATCH] Merged HEAD-BUG-FIX (4.3/Cloud) to HEAD (4.3/Cloud) 69950: Merged V4.2-BUG-FIX (4.2.3) to HEAD-BUG-FIX (4.3/Cloud) 69869: Fix action's runAs user (found investigating MNT-11310) git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@70466 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261 --- source/java/org/alfresco/repo/action/ActionServiceImpl.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/source/java/org/alfresco/repo/action/ActionServiceImpl.java b/source/java/org/alfresco/repo/action/ActionServiceImpl.java index 3be380f5ee..eaf3276df7 100644 --- a/source/java/org/alfresco/repo/action/ActionServiceImpl.java +++ b/source/java/org/alfresco/repo/action/ActionServiceImpl.java @@ -38,6 +38,7 @@ import org.alfresco.repo.copy.DefaultCopyBehaviourCallback; import org.alfresco.repo.policy.JavaBehaviour; import org.alfresco.repo.policy.PolicyComponent; import org.alfresco.repo.security.authentication.AuthenticationContext; +import org.alfresco.repo.security.authentication.AuthenticationUtil; import org.alfresco.repo.tenant.TenantUtil; import org.alfresco.repo.transaction.AlfrescoTransactionSupport; import org.alfresco.service.cmr.action.Action; @@ -1624,9 +1625,9 @@ public class ActionServiceImpl implements ActionService, RuntimeActionService, A // Set the run as user to the current user if (logger.isDebugEnabled() == true) { - logger.debug("The current user is: " + this.authenticationContext.getCurrentUserName()); + logger.debug("The current user is: " + AuthenticationUtil.getRunAsUser()); } - ((ActionImpl) action).setRunAsUser(this.authenticationContext.getCurrentUserName()); + ((ActionImpl) action).setRunAsUser(AuthenticationUtil.getRunAsUser()); // Set the tenant context to the current tenant if (logger.isDebugEnabled() == true)