From 04eefc1ae2d7450836a523a1715bb6e512db7d91 Mon Sep 17 00:00:00 2001 From: ammarahm-ed Date: Wed, 30 Aug 2023 14:49:04 +0500 Subject: [PATCH] fix migration --- ios/MMKVNative.mm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ios/MMKVNative.mm b/ios/MMKVNative.mm index c7fcfb8a..9de0c158 100644 --- a/ios/MMKVNative.mm +++ b/ios/MMKVNative.mm @@ -240,9 +240,9 @@ void upgradeIndex(MMKV *kv, NSString * type) { if (![kv containsKey:type]) return; NSMutableArray *array = [kv getObjectOfClass:NSMutableArray.class forKey:type]; if (array.count) { - NSDictionary *dic = [NSDictionary dictionary]; + NSMutableDictionary *dic = [NSMutableDictionary dictionary]; for (int i=0;i < array.count;i++) { - [dic setValue:0 forKey:array[i]]; + [dic setValue:@1 forKey:array[i]]; } [kv setObject:dic forKey:type]; }