idwise-nfc-react-native-sdk 5.7.8 → 5.8.0

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.
@@ -16,7 +16,7 @@ Pod::Spec.new do |s|
16
16
  s.source_files = "ios/**/*.{h,m,mm,cpp,swift}"
17
17
  s.private_header_files = "ios/**/*.h"
18
18
 
19
- s.dependency 'IDWiseNFC', '5.7.5'
19
+ s.dependency 'IDWiseNFC', '5.7.9'
20
20
 
21
21
  s.pod_target_xcconfig = {
22
22
  "HEADER_SEARCH_PATHS" => "\"$(PODS_ROOT)/boost\"",
@@ -4,4 +4,4 @@ IdwiseReactNativeSdk_targetSdkVersion=34
4
4
  IdwiseReactNativeSdk_compileSdkVersion=35
5
5
  IdwiseReactNativeSdk_ndkVersion=27.1.12297006
6
6
  # Idwise SDK version
7
- idwise_sdk_version=5.7.7
7
+ idwise_sdk_version=5.7.9
@@ -18,6 +18,7 @@ import com.idwise.sdk.IDWiseJourneyCallbacks
18
18
  import com.idwise.sdk.IDWiseStepCallbacks
19
19
  import com.idwise.sdk.data.models.*
20
20
  import java.io.ByteArrayOutputStream
21
+ import org.json.JSONObject
21
22
 
22
23
  @ReactModule(name = IdwiseReactNativeSdkModule.NAME)
23
24
  class IdwiseReactNativeSdkModule(private val reactContext: ReactApplicationContext) :
@@ -212,7 +213,10 @@ class IdwiseReactNativeSdkModule(private val reactContext: ReactApplicationConte
212
213
 
213
214
  override fun onError(error: IDWiseError) {
214
215
  val params: WritableMap = Arguments.createMap()
215
- params.putString("data", objectMapper.writeValueAsString(error))
216
+ val errorMap = JSONObject()
217
+ errorMap.put("code", error.code)
218
+ errorMap.put("message", error.message)
219
+ params.putString("data", errorMap.toString())
216
220
  sendEvent("onJourneyError", params)
217
221
  }
218
222
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "idwise-nfc-react-native-sdk",
3
- "version": "5.7.8",
3
+ "version": "5.8.0",
4
4
  "description": "React-Native Wrapper for IDWise SDK",
5
5
  "main": "./lib/index.js",
6
6
  "react-native": "./src/index.js",