From 8e47af2b3620c920116ec056173277c039163ec1 Mon Sep 17 00:00:00 2001 From: ArthurHoaro Date: Thu, 23 Jan 2020 21:52:03 +0100 Subject: Process logout through Slim controller --- index.php | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'index.php') diff --git a/index.php b/index.php index 73d9e022..57e13d4e 100644 --- a/index.php +++ b/index.php @@ -604,10 +604,7 @@ function renderPage($conf, $pluginManager, $bookmarkService, $history, $sessionM } // -------- User wants to logout. if (isset($_SERVER['QUERY_STRING']) && startsWith($_SERVER['QUERY_STRING'], 'do=logout')) { - invalidateCaches($conf->get('resource.page_cache')); - $sessionManager->logout(); - setcookie(LoginManager::$STAY_SIGNED_IN_COOKIE, 'false', 0, WEB_PATH); - header('Location: ?'); + header('Location: ./logout'); exit; } @@ -1894,7 +1891,7 @@ if (isset($_SERVER['QUERY_STRING']) && startsWith($_SERVER['QUERY_STRING'], 'do= exit; } -$containerBuilder = new ContainerBuilder($conf, $sessionManager, $loginManager); +$containerBuilder = new ContainerBuilder($conf, $sessionManager, $loginManager, WEB_PATH); $container = $containerBuilder->build(); $app = new App($container); -- cgit v1.2.3