If the css in cookie is invalid, clear it so that the logs don't fill up with the warnings

pull/3680/head
Isaac Connor 2023-03-21 13:25:30 -04:00
parent 6c8a2ad05a
commit 764d48d378
1 changed files with 4 additions and 0 deletions

View File

@ -110,6 +110,10 @@ if (!is_dir("skins/$skin/css/$css")) {
if (!in_array($css, $css_skins)) {
ZM\Error("Invalid skin css '$css' setting to " . $css_skins[0]);
$css = $css_skins[0];
if (isset($_COOKIE['zmCSS'])) {
unset($_COOKIE['zmCSS']);
setcookie('zmCSS', '', time() - 3600);
}
} else {
$css = '';
}