diff --git a/src/libs/localStore/storage.ts b/src/libs/localStore/storage.ts index 1f1ec6d15..e60ba7370 100644 --- a/src/libs/localStore/storage.ts +++ b/src/libs/localStore/storage.ts @@ -14,7 +14,7 @@ const log = logger('storage.ts') export const storage = new MMKV() -const { getItem, removeItem, clear } = AsyncStorage +const { removeItem, clear } = AsyncStorage export type StorageKey = CozyPersistedStorageKeys | DevicePersistedStorageKeys @@ -103,20 +103,6 @@ export const getData = async (name: StorageKey): Promise => { ? (JSON.parse(value) as T) : null } catch (error) { - /* - If we tried to parse the default redirection url and it failed, we return it as is - because previously it was stored as a string where as now it is stored as a stringified string. - - Default redirection url is written often, so active users - will automatically remove the old format from their local storage. - - In some weeks we will be able to remove this compatibility code. - */ - if (name === CozyPersistedStorageKeys.DefaultRedirectionUrl) { - const value = await getItem(name) - return value as T - } - log.error(`Failed to get key "${name}" from persistent storage`, error) return null }