MCPcopy Index your code
hub / github.com/debug-js/debug / localstorage

Function localstorage

src/browser.js:247–256  ·  view source on GitHub ↗

* Localstorage attempts to return the localstorage. * * This is necessary because safari throws * when a user disables cookies/localstorage * and you attempt to access it. * * @return {LocalStorage} * @api private

()

Source from the content-addressed store, hash-verified

245 */
246
247function localstorage() {
248 try {
249 // TVMLKit (Apple TV JS Runtime) does not have a window object, just localStorage in the global context
250 // The Browser also has localStorage in the global context.
251 return localStorage;
252 } catch (error) {
253 // Swallow
254 // XXX (@Qix-) should we be logging these?
255 }
256}
257
258module.exports = require('./common')(exports);
259

Callers 1

browser.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…