mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-25 10:09:20 +03:00
parent
91f3c05d5e
commit
502aebdc37
7 changed files with 47 additions and 29 deletions
|
|
@ -7,7 +7,7 @@ class Utils
|
|||
/**
|
||||
* @var string
|
||||
*/
|
||||
static $CookieDefaultPath = '/';
|
||||
static $CookieDefaultPath = '';
|
||||
|
||||
static $Cookies = null;
|
||||
|
||||
|
|
@ -518,6 +518,7 @@ class Utils
|
|||
if (null === $sPath)
|
||||
{
|
||||
$sPath = \RainLoop\Utils::$CookieDefaultPath;
|
||||
$sPath = $sPath && 0 < \strlen($sPath) ? $sPath : null;
|
||||
}
|
||||
|
||||
\RainLoop\Utils::$Cookies[$sName] = $sValue;
|
||||
|
|
@ -531,8 +532,11 @@ class Utils
|
|||
\RainLoop\Utils::$Cookies = is_array($_COOKIE) ? $_COOKIE : array();
|
||||
}
|
||||
|
||||
$sPath = \RainLoop\Utils::$CookieDefaultPath;
|
||||
$sPath = $sPath && 0 < \strlen($sPath) ? $sPath : null;
|
||||
|
||||
unset(\RainLoop\Utils::$Cookies[$sName]);
|
||||
@\setcookie($sName, '', \time() - 3600 * 24 * 30);
|
||||
@\setcookie($sName, '', \time() - 3600 * 24 * 30, $sPath);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue