From 8111710a09864a628b5a9e928dcd46cab612484a Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim=20D=C3=BCsterhus?= Date: Wed, 20 Jan 2021 17:05:15 +0100 Subject: [PATCH] Fix disabling of session ACP expiration in debug + dev mode While this was properly accounted for in SessionHandler::prune() it was not when loading the session. --- .../install/files/lib/system/session/SessionHandler.class.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/wcfsetup/install/files/lib/system/session/SessionHandler.class.php b/wcfsetup/install/files/lib/system/session/SessionHandler.class.php index 4b66a5d232..14b8742486 100644 --- a/wcfsetup/install/files/lib/system/session/SessionHandler.class.php +++ b/wcfsetup/install/files/lib/system/session/SessionHandler.class.php @@ -576,7 +576,9 @@ final class SessionHandler extends SingletonFactory { ($row['userID'] ? self::USER_SESSION_LIFETIME : ( self::GUEST_SESSION_LIFETIME))); if ($row['lastActivityTime'] < (TIME_NOW - $lifetime)) { - return false; + if (!$this->isACP || !ENABLE_DEBUG_MODE || !ENABLE_DEVELOPER_TOOLS) { + return false; + } } $variables = @\unserialize($row['sessionVariables']); -- 2.20.1