mirror of
https://github.com/pretix/pretix.git
synced 2026-05-05 15:14:04 +00:00
Cookie consent: Fix crash without localStorage again
This commit is contained in:
@@ -5,7 +5,7 @@ $(function () {
|
||||
|
||||
var storage_key = $("#cookie-consent-storage-key").text();
|
||||
function update_consent(consent) {
|
||||
if (storage_key) window.localStorage[storage_key] = JSON.stringify(consent);
|
||||
if (storage_key && window.localStorage) window.localStorage[storage_key] = JSON.stringify(consent);
|
||||
window.pretix.cookie_consent = consent;
|
||||
|
||||
// Event() is not supported by IE11, see ployfill here:
|
||||
|
||||
Reference in New Issue
Block a user