로그아웃 인증 정리
This commit is contained in:
@@ -707,6 +707,22 @@ function control_admin_session_from_rhymix_or_custom(): bool
|
||||
return $checked;
|
||||
}
|
||||
|
||||
function clear_common_admin_auth_cookie_if_available(): void
|
||||
{
|
||||
$commonAuth = '/mnt/synology-web/custom/common/auth.php';
|
||||
if (!is_file($commonAuth) || !is_readable($commonAuth)) {
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
require_once $commonAuth;
|
||||
if (function_exists('custom_clear_auth_cookie')) {
|
||||
custom_clear_auth_cookie();
|
||||
}
|
||||
} catch (Throwable) {
|
||||
}
|
||||
}
|
||||
|
||||
function require_login(): void
|
||||
{
|
||||
if (!signed_in()) {
|
||||
|
||||
Reference in New Issue
Block a user