()
| 89 | } |
| 90 | |
| 91 | saveCachedToken() { |
| 92 | if (!this.authorization) return; |
| 93 | const cache = readTokenCache(); |
| 94 | cache[this.openid] = { |
| 95 | authorization: this.authorization, |
| 96 | refreshToken: this.refreshToken, |
| 97 | nickname: this.user.nickname || "", |
| 98 | mobile: this.user.mobile || "", |
| 99 | updatedAt: new Date().toISOString(), |
| 100 | }; |
| 101 | writeTokenCache(cache); |
| 102 | } |
| 103 | |
| 104 | removeCachedToken() { |
| 105 | const cache = readTokenCache(); |
no test coverage detected