fix: c30374732e
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Baoshuo Ren 2022-10-04 16:33:24 +08:00
parent 8a288ceff5
commit 8703631db8
Signed by: baoshuo
GPG Key ID: 00CB9680AB29F51A

View File

@ -80,7 +80,8 @@ class Auth {
} }
if ($myUser) { if ($myUser) {
if (!isset($_SESSION['last_login']) || (time() - $_SESSION['last_login']) > 60 * 60 * 24 * 7) { // 1 week if (!isset($_SESSION['last_login'])) $_SESSION['last_login'] = $myUser['last_login'];
if ((time() - $_SESSION['last_login']) > 60 * 60 * 24 * 7) { // 1 week
Auth::logout(); Auth::logout();
$myUser = null; $myUser = null;
} }