()
| 23 | } |
| 24 | |
| 25 | save () { |
| 26 | const arr = [] |
| 27 | for (const [key, value] of this.cache) { |
| 28 | arr.push({ |
| 29 | key, |
| 30 | value |
| 31 | }) |
| 32 | } |
| 33 | safeSetItem(this.key, JSON.stringify(arr)) |
| 34 | } |
| 35 | |
| 36 | set (key, value) { |
| 37 | this.cache.set(key, value) |
no test coverage detected