From 217df2c9b50a3bb952b278288763701ce509b026 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Tue, 25 Nov 2014 20:37:15 +0100 Subject: [PATCH] work-around for weird localStorage behavior in Safari OS X/iOS --- wcfsetup/install/files/js/3rdParty/redactor/plugins/wutil.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wutil.js b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wutil.js index be50ecfc01..35d37ef0e3 100644 --- a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wutil.js +++ b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wutil.js @@ -443,7 +443,7 @@ RedactorPlugins.wutil = function() { $value = { timestamp: 0 }; } - if (!$value.timestamp || $value.timestamp < $oneWeekAgo) { + if ($value === null || !$value.timestamp || $value.timestamp < $oneWeekAgo) { try { localStorage.removeItem($key); } -- 2.20.1