Adjusted log severity
Improved error reporting
Improved token handling
Improved Config Form handling
This commit is contained in:
Joey Kimsey
2025-01-21 20:35:24 -05:00
parent 42ade08306
commit 3152d180c0
7 changed files with 93 additions and 65 deletions

View File

@ -31,7 +31,7 @@ class Session {
if ( isset( $_SESSION[ $sessionName ] ) ) {
return true;
}
Debug::info( "Session::exists - Session not found: $sessionName" );
Debug::log( "Session::exists - Session not found: $sessionName" );
return false;
}
@ -49,7 +49,7 @@ class Session {
if ( self::exists( $name ) ) {
return $_SESSION[ $sessionName ];
}
Debug::info( "Session::get - Session not found: $sessionName" );
Debug::log( "Session::get - Session not found: $sessionName" );
return false;
}
@ -69,7 +69,7 @@ class Session {
}
$sessionName = DEFAULT_SESSION_PREFIX . $name;
$_SESSION[ $sessionName ] = $data;
Debug::info( "Session::get - Created/Updated: $sessionName" );
Debug::log( "Session::get - Created/Updated: $sessionName" );
return true;
}
@ -107,7 +107,7 @@ class Session {
return false;
}
if ( self::exists( $name ) ) {
Debug::info("Session::flash - Exists");
Debug::log("Session::flash - Exists");
$session = self::get( $name );
self::delete( $name );
return $session;
@ -121,11 +121,11 @@ class Session {
}
if ( ! empty( $data ) ) {
self::put( $name, $data );
Debug::info("Session::flash - Session created.");
Debug::log("Session::flash - Session created.");
return true;
}
if ( self::exists( $name ) ) {
Debug::info("Session::flash - Exists");
Debug::log("Session::flash - Exists");
$session = self::get( $name );
self::delete( $name );
return $session;