MCPcopy Create free account
hub / github.com/smallfawn/QLScriptPublic / saveCache

Method saveCache

wxapp/airui.js:139–149  ·  view source on GitHub ↗
(extra = {})

Source from the content-addressed store, hash-verified

137 }
138
139 saveCache(extra = {}) {
140 const cache = readCache();
141 cache[this.cacheKey] = {
142 ...(cache[this.cacheKey] || {}),
143 ...(this.token ? { token: this.token } : {}),
144 ...(this.userId ? { userId: this.userId } : {}),
145 ...extra,
146 updatedAt: new Date().toISOString(),
147 };
148 writeCache(cache);
149 }
150
151 removeToken() {
152 const cache = readCache();

Callers 2

loginMethod · 0.95
getUserInfoMethod · 0.95

Calls 2

readCacheFunction · 0.70
writeCacheFunction · 0.70

Tested by

no test coverage detected