react-native-authsignal 2.2.6 → 2.2.7

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.
@@ -172,7 +172,12 @@ class AuthsignalInAppModule(private val reactContext: ReactApplicationContext) :
172
172
 
173
173
  promise.reject(errorCode, response.error)
174
174
  } else {
175
- promise.resolve(response.data)
175
+ val data = response.data!!
176
+ val map = Arguments.createMap()
177
+ map.putBoolean("isVerified", data.isVerified)
178
+ map.putString("token", data.token)
179
+ map.putString("userId", data.userId)
180
+ promise.resolve(map)
176
181
  }
177
182
  }
178
183
  }
@@ -219,7 +219,13 @@ class AuthsignalInAppModule: NSObject {
219
219
  if let error = response.error {
220
220
  reject(response.errorCode ?? "unexpected_error", error, nil)
221
221
  } else {
222
- resolve(response.data)
222
+ let verifyPinResponse: [String: Any?] = [
223
+ "isVerified": response.data!.isVerified,
224
+ "token": response.data!.token,
225
+ "userId": response.data!.userId,
226
+ ]
227
+
228
+ resolve(verifyPinResponse)
223
229
  }
224
230
  }
225
231
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-authsignal",
3
- "version": "2.2.6",
3
+ "version": "2.2.7",
4
4
  "description": "The official Authsignal React Native library.",
5
5
  "main": "lib/commonjs/index",
6
6
  "module": "lib/module/index",