We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 450c911 commit 982f66fCopy full SHA for 982f66f
src/utils/index.ts
@@ -23,12 +23,12 @@ const themeSetup = () => {
23
}
24
25
26
-const clearCache = () => {
+const clearCache = async () => {
27
// clear local storage all data.
28
- localStorage.clear();
+ await localStorage.clear();
29
30
// clear all cache data.
31
- caches.keys().then((keyList: any) =>
+ await caches.keys().then((keyList: any) =>
32
Promise.all(
33
keyList.map((key: any) => {
34
return caches.delete(key);
@@ -49,4 +49,5 @@ export {
49
themeSetup,
50
urls,
51
recaptchaToken,
52
+ clearCache,
53
0 commit comments