This commit is contained in:
ansuz 2017-06-13 12:24:32 +02:00
parent 7ad89bd9af
commit 1b574da053
1 changed files with 2 additions and 1 deletions

View File

@ -21,6 +21,7 @@ define([], function () {
} }
var failStore = function () { var failStore = function () {
console.error(new Error('wut'));
require(['jquery'], function ($) { require(['jquery'], function ($) {
$.ajax({ $.ajax({
type: 'HEAD', type: 'HEAD',
@ -34,7 +35,7 @@ define([], function () {
var test_key = 'localStorage_test'; var test_key = 'localStorage_test';
var testval = Math.random().toString(); var testval = Math.random().toString();
localStorage.setItem(test_key, testval); localStorage.setItem(test_key, testval);
if (localStorage.getItem(test_key) !== test_key) { if (localStorage.getItem(test_key) !== testval) {
failStore(); failStore();
} }
} catch (e) { console.error(e); failStore(); } } catch (e) { console.error(e); failStore(); }