paynl-pos-sdk-react-native 0.0.21 → 0.0.22

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.
@@ -50,11 +50,12 @@ import PayNlPOSSdkSwift
50
50
  resolve("ready_for_payment")
51
51
  break
52
52
 
53
- case .failed(_):
54
- resolve("failed")
53
+ case .failed(let error):
54
+ reject(error.code, error.description, error)
55
55
  break
56
+
56
57
  @unknown default:
57
- resolve("failed")
58
+ reject("SV-0000", "UNKNOWN ERROR", PayNlSVError.UNEXPECTED_ERROR("UNKNOWN ERROR"))
58
59
  break
59
60
  }
60
61
  }
@@ -164,7 +165,7 @@ import PayNlPOSSdkSwift
164
165
  ]
165
166
  } as NSArray
166
167
  }
167
-
168
+
168
169
  @objc public func sendTicket(email: String, transactionId: String, ticket: String, resolve: @escaping RCTPromiseResolveBlock, rejecter reject: @escaping RCTPromiseRejectBlock) {
169
170
  Task {
170
171
  do {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "paynl-pos-sdk-react-native",
3
- "version": "0.0.21",
3
+ "version": "0.0.22",
4
4
  "description": "A PayNL sdk to accept and process payments",
5
5
  "source": "./src/index.tsx",
6
6
  "main": "./lib/commonjs/index.js",