mirror of
https://github.com/chatwoot/chatwoot.git
synced 2026-06-04 21:02:35 +08:00
Fix STORAGE_BUSY error in firefox
This commit is contained in:
parent
b1828d462d
commit
a68e736cfc
@ -4,11 +4,11 @@ export const LocalStorage = {
|
||||
},
|
||||
|
||||
get(key) {
|
||||
const value = window.localStorage.getItem(key);
|
||||
try {
|
||||
const value = window.localStorage.getItem(key);
|
||||
return typeof value === 'string' ? JSON.parse(value) : value;
|
||||
} catch (error) {
|
||||
return value;
|
||||
return undefined;
|
||||
}
|
||||
},
|
||||
set(key, value) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user