ok
This commit is contained in:
parent
46d90459d0
commit
a7180b3262
2 changed files with 11 additions and 11 deletions
|
@ -242,7 +242,7 @@ export default defineComponent({
|
||||||
addAcount() {
|
addAcount() {
|
||||||
os.popup(import('./signin-dialog.vue'), {}, {
|
os.popup(import('./signin-dialog.vue'), {}, {
|
||||||
done: async res => {
|
done: async res => {
|
||||||
addAccount(res.id, res.i);
|
await addAccount(res.id, res.i);
|
||||||
os.success();
|
os.success();
|
||||||
},
|
},
|
||||||
}, 'closed');
|
}, 'closed');
|
||||||
|
|
|
@ -9,7 +9,7 @@ const fallbackName = (key: string) => `idbfallback::${key}`;
|
||||||
|
|
||||||
export async function get(key: string) {
|
export async function get(key: string) {
|
||||||
if (window.indexedDB) return iget(key);
|
if (window.indexedDB) return iget(key);
|
||||||
return JSON.parse(localStorage.getItem(fallbackName(key)) || 'null');
|
return JSON.parse(localStorage.getItem(fallbackName(key)));
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function set(key: string, val: any) {
|
export async function set(key: string, val: any) {
|
||||||
|
|
Loading…
Reference in a new issue