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

Method saveCachedToken

wxapp/ykb_all.js:253–267  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

251 }
252
253 saveCachedToken() {
254 if (!this.token) return;
255 const cache = readTokenCache();
256 cache[this.cacheKey()] = {
257 token: this.token,
258 openId: this.openId,
259 mallCode: this.mallCode,
260 h5Prefix: this.h5Prefix,
261 customerName: this.customerName,
262 appid: this.app.appid,
263 appName: this.app.name,
264 updatedAt: new Date().toISOString(),
265 };
266 writeTokenCache(cache);
267 }
268
269 removeCachedToken() {
270 const cache = readTokenCache();

Callers 1

loginMethod · 0.95

Calls 3

cacheKeyMethod · 0.95
readTokenCacheFunction · 0.70
writeTokenCacheFunction · 0.70

Tested by

no test coverage detected