wip: refactor
This commit is contained in:
@@ -184,6 +184,12 @@ export class LumeStorage {
|
||||
);
|
||||
}
|
||||
|
||||
public async removePrivkey() {
|
||||
return await this.db.execute(
|
||||
`UPDATE accounts SET privkey = "privkey is stored in secure storage" WHERE id = "${this.account.id}";`
|
||||
);
|
||||
}
|
||||
|
||||
public async close() {
|
||||
return this.db.close();
|
||||
}
|
||||
|
||||
@@ -24,10 +24,6 @@ const StorageProvider = ({ children }: PropsWithChildren<object>) => {
|
||||
|
||||
useEffect(() => {
|
||||
if (!db) initLumeStorage();
|
||||
|
||||
return () => {
|
||||
db.close();
|
||||
};
|
||||
}, []);
|
||||
|
||||
if (db) {
|
||||
|
||||
Reference in New Issue
Block a user