@onekeyfe/react-native-async-storage 3.0.15 → 3.0.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -19,7 +19,7 @@ import java.util.concurrent.Executors
|
|
|
19
19
|
*/
|
|
20
20
|
@ReactModule(name = RNCAsyncStorageModule.NAME)
|
|
21
21
|
class RNCAsyncStorageModule(reactContext: ReactApplicationContext) :
|
|
22
|
-
|
|
22
|
+
NativeAsyncStorageSpec(reactContext) {
|
|
23
23
|
|
|
24
24
|
companion object {
|
|
25
25
|
const val NAME = "RNCAsyncStorage"
|
|
@@ -71,7 +71,7 @@ class RNCAsyncStorageModule(reactContext: ReactApplicationContext) :
|
|
|
71
71
|
try {
|
|
72
72
|
if (cursor.count != keys.size()) {
|
|
73
73
|
for (keyIndex in keyStart until keyStart + keyCount) {
|
|
74
|
-
keysRemaining.add(keys.getString(keyIndex))
|
|
74
|
+
keysRemaining.add(keys.getString(keyIndex) ?: "")
|
|
75
75
|
}
|
|
76
76
|
}
|
|
77
77
|
if (cursor.moveToFirst()) {
|
|
@@ -304,7 +304,7 @@ class RNCAsyncStorageModule(reactContext: ReactApplicationContext) :
|
|
|
304
304
|
}
|
|
305
305
|
|
|
306
306
|
private fun buildKeySelectionArgs(keys: ReadableArray, start: Int, count: Int): Array<String> {
|
|
307
|
-
return Array(count) { keys.getString(start + it) }
|
|
307
|
+
return Array(count) { keys.getString(start + it) ?: "" }
|
|
308
308
|
}
|
|
309
309
|
|
|
310
310
|
private fun getItemImpl(key: String): String? {
|