1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

create localStorage abstraction

This commit is contained in:
Luke Pulverenti 2014-07-15 15:16:16 -04:00
parent ecba850f43
commit c5a40e9616
19 changed files with 138 additions and 103 deletions

View file

@ -22,7 +22,7 @@
var deferred = $.Deferred();
var data = sessionStorage.getItem(key);
var data = sessionStore.getItem(key);
if (data) {
@ -51,7 +51,7 @@
};
});
sessionStorage.setItem(key, JSON.stringify(images));
sessionStore.setItem(key, JSON.stringify(images));
deferred.resolveWith(null, [images]);
});
}
@ -101,7 +101,7 @@
var userId = Dashboard.getCurrentUserId();
var val = LocalSettings.val('enableBackdrops', userId);
var val = store.getItem('enableBackdrops', userId);
// For bandwidth
return val == '1' || (val != '0' && !$.browser.mobile);