Skip to content

Commit ad83f2c

Browse files
committed
fix: op-sqlite patch to include return types, othewise rn 0.83 errors on app start
1 parent 3de6c1e commit ad83f2c

2 files changed

Lines changed: 11 additions & 10 deletions

File tree

.yarn/patches/@op-engineering-op-sqlite-npm-15.2.5-936f5cf3a5.patch

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ index 5912d7b..495880e 100644
9494

9595
JNIEXPORT jint JNI_OnLoad(JavaVM *vm, void *) {
9696
diff --git a/android/src/main/java/com/op/sqlite/OPSQLiteBridge.kt b/android/src/main/java/com/op/sqlite/OPSQLiteBridge.kt
97-
index 44f86df..9d9f710 100644
97+
index 44f86df..8c003db 100644
9898
--- a/android/src/main/java/com/op/sqlite/OPSQLiteBridge.kt
9999
+++ b/android/src/main/java/com/op/sqlite/OPSQLiteBridge.kt
100100
@@ -12,6 +12,7 @@ class OPSQLiteBridge {
@@ -109,15 +109,15 @@ index 44f86df..9d9f710 100644
109109
clearStateNativeJsi()
110110
}
111111

112-
+ fun deleteAllDBs() {
113-
+ deleteAllDBsJsi()
112+
+ fun deleteAllDBs(): Boolean {
113+
+ return deleteAllDBsJsi()
114114
+ }
115115
+
116116
companion object {
117117
val instance = OPSQLiteBridge()
118118
}
119119
diff --git a/android/src/main/java/com/op/sqlite/OPSQLiteModule.kt b/android/src/main/java/com/op/sqlite/OPSQLiteModule.kt
120-
index 8d341b7..3ce6179 100644
120+
index 8d341b7..33d3d7d 100644
121121
--- a/android/src/main/java/com/op/sqlite/OPSQLiteModule.kt
122122
+++ b/android/src/main/java/com/op/sqlite/OPSQLiteModule.kt
123123
@@ -12,7 +12,7 @@ import java.io.InputStream
@@ -129,18 +129,19 @@ index 8d341b7..3ce6179 100644
129129
override fun getName(): String {
130130
return NAME
131131
}
132-
@@ -54,6 +54,17 @@ internal class OPSQLiteModule(context: ReactApplicationContext?) : ReactContextB
132+
@@ -54,6 +54,18 @@ internal class OPSQLiteModule(context: ReactApplicationContext?) : ReactContextB
133133
throw Exception("Do not call getDylibPath on Android")
134134
}
135135

136136
+ @ReactMethod(isBlockingSynchronousMethod = true)
137-
+ fun closeAllConnections() {
137+
+ fun closeAllConnections(): Boolean {
138138
+ OPSQLiteBridge.instance.invalidate()
139+
+ return true
139140
+ }
140141
+
141142
+ @ReactMethod(isBlockingSynchronousMethod = true)
142-
+ fun deleteAllDBs() {
143-
+ OPSQLiteBridge.instance.deleteAllDBs();
143+
+ fun deleteAllDBs(): Boolean {
144+
+ return OPSQLiteBridge.instance.deleteAllDBs();
144145
+ }
145146
+
146147
+

yarn.lock

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2774,11 +2774,11 @@ __metadata:
27742774

27752775
"@op-engineering/op-sqlite@patch:@op-engineering/op-sqlite@npm%3A15.2.5#./.yarn/patches/@op-engineering-op-sqlite-npm-15.2.5-936f5cf3a5.patch::locator=mendix-native%40workspace%3A.":
27762776
version: 15.2.5
2777-
resolution: "@op-engineering/op-sqlite@patch:@op-engineering/op-sqlite@npm%3A15.2.5#./.yarn/patches/@op-engineering-op-sqlite-npm-15.2.5-936f5cf3a5.patch::version=15.2.5&hash=3aa266&locator=mendix-native%40workspace%3A."
2777+
resolution: "@op-engineering/op-sqlite@patch:@op-engineering/op-sqlite@npm%3A15.2.5#./.yarn/patches/@op-engineering-op-sqlite-npm-15.2.5-936f5cf3a5.patch::version=15.2.5&hash=1ffd55&locator=mendix-native%40workspace%3A."
27782778
peerDependencies:
27792779
react: "*"
27802780
react-native: "*"
2781-
checksum: 10/eda7022712e2aa6debd39e067e85901fabc2ea700d1a9fdb5f8d8558a381f10c2d37487ecb6dd460b69a3376df5aef04df836a8315d5e114d86255da013cd93e
2781+
checksum: 10/2d549579379d04b046d629e9c8df72d72c1a96813cb7999f8d618af4564c254f26013220f7ba3ddf25143f50cdaafb283b2bab85c52f44a19c23d8532a958045
27822782
languageName: node
27832783
linkType: hard
27842784

0 commit comments

Comments
 (0)