From 1b162fc8657cc57dfaaa4551fe57244eed0df059 Mon Sep 17 00:00:00 2001 From: Sofien Haj Chedhli Date: Tue, 17 Feb 2026 12:41:12 +0100 Subject: [PATCH] fix: Space created by non admin results to not found page - MEED-10255 - Meeds-io/meeds#4053 (#129) Prior to this change, creating a new space with a simple user redirected the user to the Not Found page, making the space inaccessible. The issue occurred because the role was not properly fetched due to the request lifecycle transaction not being restarted. This update restarts the transaction after the membership update, ensuring the role is correctly retrieved and resolving the issue. --- .../services/organization/impl/MembershipUpdateListener.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipUpdateListener.java b/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipUpdateListener.java index 70469400f..2d84105ad 100644 --- a/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipUpdateListener.java +++ b/exo.core.component.organization.api/src/main/java/org/exoplatform/services/organization/impl/MembershipUpdateListener.java @@ -23,6 +23,8 @@ import org.exoplatform.services.security.ConversationRegistry; import org.exoplatform.services.security.IdentityRegistry; +import static org.exoplatform.container.component.RequestLifeCycle.restartTransaction; + public class MembershipUpdateListener extends MembershipEventListener { private final ConversationRegistry conversationRegistry; @@ -47,6 +49,7 @@ public void postSave(Membership m, boolean isNew) throws Exception { private void refreshUserIdentity(String username) { conversationRegistry.unregisterByUserId(username); identityRegistry.unregister(username); + restartTransaction(); } }