(cache)
| 54 | } |
| 55 | |
| 56 | function writeCache(cache) { |
| 57 | try { |
| 58 | fs.writeFileSync(TOKEN_CACHE_FILE, JSON.stringify(cache, null, 2)); |
| 59 | } catch (e) { |
| 60 | $.log(`⚠️ token缓存写入失败: ${e.message}`); |
| 61 | } |
| 62 | } |
| 63 | |
| 64 | function updateCachedToken(account, token) { |
| 65 | if (!account || !token || isToken(account)) return; |
no test coverage detected