From 89612bddbc391d07ccf96bea04777bda81283a9c Mon Sep 17 00:00:00 2001 From: cdujeu Date: Wed, 9 Nov 2016 10:37:03 +0100 Subject: [PATCH] Make sure to save repoId in session when loading minisite, can make some issues if shared user have other workspaces accesses. --- .../plugins/action.share/src/Http/MinisiteAuthMiddleware.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/core/src/plugins/action.share/src/Http/MinisiteAuthMiddleware.php b/core/src/plugins/action.share/src/Http/MinisiteAuthMiddleware.php index fecf15cc27..623a7d645b 100644 --- a/core/src/plugins/action.share/src/Http/MinisiteAuthMiddleware.php +++ b/core/src/plugins/action.share/src/Http/MinisiteAuthMiddleware.php @@ -98,6 +98,9 @@ public static function handleRequest(ServerRequestInterface $requestInterface, R if(!empty($ctx) && $ctx->hasUser() && isSet($shareData["REPOSITORY"])){ $repoObject = UsersService::getRepositoryWithPermission($ctx->getUser(), $shareData["REPOSITORY"]); $ctx->setRepositoryObject($repoObject); + if($sessions){ + SessionService::saveRepositoryId($shareData["REPOSITORY"]); + } $requestInterface = $requestInterface->withAttribute("ctx", $ctx); }