react-native-ble-manager 11.0.7 → 11.0.8
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.
- package/android/build.gradle +6 -1
- package/ios/BleManager.swift +3 -8
- package/package.json +1 -1
package/android/build.gradle
CHANGED
|
@@ -20,6 +20,11 @@ def safeExtGet(prop, fallback) {
|
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
android {
|
|
23
|
+
def agpVersion = com.android.Version.ANDROID_GRADLE_PLUGIN_VERSION
|
|
24
|
+
if (agpVersion.tokenize('.')[0].toInteger() >= 7) {
|
|
25
|
+
namespace "it.innove"
|
|
26
|
+
}
|
|
27
|
+
|
|
23
28
|
compileSdk safeExtGet("compileSdk", 33)
|
|
24
29
|
|
|
25
30
|
compileOptions {
|
|
@@ -51,4 +56,4 @@ repositories {
|
|
|
51
56
|
dependencies {
|
|
52
57
|
implementation "com.facebook.react:react-native:+"
|
|
53
58
|
// implementation "org.jetbrains.trove4j: trove4j: 20160824"
|
|
54
|
-
}
|
|
59
|
+
}
|
package/ios/BleManager.swift
CHANGED
|
@@ -111,14 +111,9 @@ class BleManager: RCTEventEmitter, CBCentralManagerDelegate, CBPeripheralDelegat
|
|
|
111
111
|
// Helper method to insert callback in different queues
|
|
112
112
|
func insertCallback(_ callback: @escaping RCTResponseSenderBlock, intoDictionary dictionary: inout Dictionary<String, [RCTResponseSenderBlock]>, withKey key: String) {
|
|
113
113
|
serialQueue.sync {
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
var peripheralCallbacks = [RCTResponseSenderBlock]()
|
|
118
|
-
peripheralCallbacks.append(callback)
|
|
119
|
-
dictionary[key] = peripheralCallbacks
|
|
120
|
-
}
|
|
121
|
-
|
|
114
|
+
var peripheralCallbacks = dictionary[key] ?? [RCTResponseSenderBlock]()
|
|
115
|
+
peripheralCallbacks.append(callback)
|
|
116
|
+
dictionary[key] = peripheralCallbacks
|
|
122
117
|
}
|
|
123
118
|
}
|
|
124
119
|
|