corrected PR for other browsers

Sorry, this should work now. window.localStorage is undefined in chrome apps.
This commit is contained in:
Zeus Gómez Marmolejo 2014-10-08 17:27:33 +02:00
parent e9c730a6e2
commit de8695b6be

View File

@ -18,7 +18,7 @@ exports.useColors = useColors;
var storage;
if (chrome.storage.local !== undefined)
if (chrome && chrome.storage)
storage = chrome.storage.local;
else
storage = window.localStorage;