Merge remote-tracking branch 'origin/master'

This commit is contained in:
Weblate 2015-10-10 03:06:05 +02:00
commit bc737700ee

View File

@ -285,17 +285,18 @@ $GLOBALS['PMA_Config']->enableBc();
* clean cookies on upgrade
* when changing something related to PMA cookies, increment the cookie version
*/
$pma_cookie_version = 4;
if (isset($_COOKIE)
&& (isset($_COOKIE['pmaCookieVer'])
&& $_COOKIE['pmaCookieVer'] < $pma_cookie_version)
) {
// delete all cookies
foreach ($_COOKIE as $cookie_name => $tmp) {
$GLOBALS['PMA_Config']->removeCookie($cookie_name);
$pma_cookie_version = 5;
if (isset($_COOKIE)) {
if (! isset($_COOKIE['pmaCookieVer'])
|| $_COOKIE['pmaCookieVer'] != $pma_cookie_version
) {
// delete all cookies
foreach ($_COOKIE as $cookie_name => $tmp) {
$GLOBALS['PMA_Config']->removeCookie($cookie_name);
}
$_COOKIE = array();
$GLOBALS['PMA_Config']->setCookie('pmaCookieVer', $pma_cookie_version);
}
$_COOKIE = array();
$GLOBALS['PMA_Config']->setCookie('pmaCookieVer', $pma_cookie_version);
}