Skip to content

Commit 3fb9177

Browse files
committed
fix: vault check
1 parent 9681db9 commit 3fb9177

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/structures/vault.local/deck.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ export default class Deck extends Base {
107107
// this.setRaw(`meta.${key}`, value);
108108
}
109109

110-
#getRaw(key) {
110+
#getRaw(key) { // TODO: Store all data in `${this.key}.meta`?
111111
this.#checkLocal();
112112
return localStorage.getItem(key ? `${this.key}.${key}` : this.key) ?? '';
113113
}
@@ -123,6 +123,6 @@ export default class Deck extends Base {
123123
}
124124

125125
#checkLocal() {
126-
if (!this.#owner || !this.#soul || !this.index) throw new Error('Not a local deck');
126+
if (!this.#owner || !this.#soul || !this.id) throw new Error('Not a local deck');
127127
}
128128
}

0 commit comments

Comments
 (0)