From 64971d62623ad1cd34349f86a05b151308ca3047 Mon Sep 17 00:00:00 2001 From: Craig Williams Date: Tue, 15 Feb 2022 17:31:29 +0000 Subject: [PATCH] Change leave redirect to organisations list page if access is granted, dashboard if otherwise --- src/Controller/OrganisationController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Controller/OrganisationController.php b/src/Controller/OrganisationController.php index c489a24..f77f648 100644 --- a/src/Controller/OrganisationController.php +++ b/src/Controller/OrganisationController.php @@ -1060,7 +1060,7 @@ class OrganisationController extends SimpleController 'fields' => $fields, 'tools' => $editButtons, 'delete_redirect' => ($canAccessOrganisations ? $this->ci->router->pathFor('uri_organisations') : $this->ci->router->pathFor('dashboard')), - 'leave_redirect' => $this->ci->router->pathFor('dashboard'), + 'leave_redirect' => ($canAccessOrganisations ? $this->ci->router->pathFor('uri_organisations') : $this->ci->router->pathFor('dashboard')), ]); }