(cache)
| 46 | } |
| 47 | |
| 48 | function writeTokenCache(cache) { |
| 49 | try { |
| 50 | fs.writeFileSync(TOKEN_CACHE_FILE, JSON.stringify(cache, null, 2), "utf8"); |
| 51 | } catch (e) { |
| 52 | $.log(`写入token缓存失败: ${e.message || e}`); |
| 53 | } |
| 54 | } |
| 55 | |
| 56 | function shortToken(token = "") { |
| 57 | const value = String(token || ""); |
no test coverage detected