MCPcopy
hub / github.com/spicetify/cli / getStorage

Method getStorage

Extensions/bookmark.js:65–76  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

63 }
64
65 getStorage() {
66 const storageRaw = LocalStorage.get(STORAGE_KEY);
67 let storage = [];
68
69 if (storageRaw) {
70 storage = JSON.parse(storageRaw);
71 } else {
72 LocalStorage.set(STORAGE_KEY, "[]");
73 }
74
75 return storage;
76 }
77
78 addToStorage(data) {
79 data.id = `${data.uri}-${new Date().getTime()}`;

Callers 3

applyMethod · 0.95
addToStorageMethod · 0.95
removeFromStorageMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected