()
| 70 | } |
| 71 | |
| 72 | disable() { |
| 73 | if (this.enabled) { |
| 74 | this.enabled = false; |
| 75 | // If this.enabled, the instance must be in storageList |
| 76 | const index = ArrayPrototypeIndexOf(storageList, this); |
| 77 | ArrayPrototypeSplice(storageList, index, 1); |
| 78 | if (storageList.length === 0) { |
| 79 | storageHook.disable(); |
| 80 | } |
| 81 | } |
| 82 | } |
| 83 | |
| 84 | _enable() { |
| 85 | if (!this.enabled) { |