From 67875e2afa65fb0be477099def0e3d9cdb08ea22 Mon Sep 17 00:00:00 2001 From: tamaina Date: Thu, 7 Oct 2021 14:28:22 +0900 Subject: [PATCH] Revert "Fix idb" This reverts commit dd17065129c66f5093add1192fcdf853123f7583. --- src/client/scripts/idb-proxy.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/client/scripts/idb-proxy.ts b/src/client/scripts/idb-proxy.ts index 5f76ae30bb..21c4dcff65 100644 --- a/src/client/scripts/idb-proxy.ts +++ b/src/client/scripts/idb-proxy.ts @@ -4,6 +4,7 @@ import { get as iget, set as iset, del as idel, + createStore, } from 'idb-keyval'; const fallbackName = (key: string) => `idbfallback::${key}`; @@ -12,9 +13,9 @@ let idbAvailable = typeof window !== 'undefined' ? !!window.indexedDB : true; if (idbAvailable) { try { - await iset('idb-test', 'test'); + await createStore('keyval-store', 'keyval'); } catch (e) { - console.error('idb error', e); + console.error('idb open error', e); idbAvailable = false; } }