mirror of
https://github.com/pi-hole/web.git
synced 2026-04-23 18:29:43 +01:00
Avoid message warnings if session was already started.
fix #2350 Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
This commit is contained in:
@@ -101,7 +101,9 @@ function check_cors()
|
||||
function check_csrf($token)
|
||||
{
|
||||
// Start a new PHP session (or continue an existing one)
|
||||
start_php_session();
|
||||
if (session_status() != PHP_SESSION_ACTIVE) {
|
||||
start_php_session();
|
||||
}
|
||||
|
||||
if (!isset($_SESSION['token'])) {
|
||||
log_and_die('Session expired! Please re-login on the Pi-hole dashboard.');
|
||||
|
||||
Reference in New Issue
Block a user