@rovenue/react-native-sdk 0.24.0 → 0.26.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.
@@ -175,8 +175,8 @@ class RovenueModule : Module() {
175
175
  val u = Rovenue.shared.currentUser()
176
176
  mapOf("rovenueId" to u.rovenueId, "appUserId" to u.appUserId)
177
177
  }
178
- AsyncFunction("identify") Coroutine { appUserId: String ->
179
- try { Rovenue.shared.identify(appUserId) } catch (e: Throwable) { throw codedError(e) }
178
+ AsyncFunction("identify") Coroutine { appUserId: String, identityToken: String ->
179
+ try { Rovenue.shared.identify(appUserId, identityToken) } catch (e: Throwable) { throw codedError(e) }
180
180
  }
181
181
  // Returns at once on Android: the façade posts in the background and
182
182
  // logs a failure rather than throwing.
@@ -0,0 +1,7 @@
1
+ // src/version.ts
2
+ var SDK_VERSION = "0.26.0";
3
+
4
+ export {
5
+ SDK_VERSION
6
+ };
7
+ //# sourceMappingURL=chunk-BORMJJTI.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/version.ts"],"sourcesContent":["/** This package's version, as published — the same string `package.json` carries. */\nexport const SDK_VERSION = \"0.24.0\";\n"],"mappings":";AACO,IAAM,cAAc;","names":[]}
1
+ {"version":3,"sources":["../src/version.ts"],"sourcesContent":["/** This package's version, as published — the same string `package.json` carries. */\nexport const SDK_VERSION = \"0.26.0\";\n"],"mappings":";AACO,IAAM,cAAc;","names":[]}
package/dist/index.cjs CHANGED
@@ -43,7 +43,7 @@ __export(index_exports, {
43
43
  module.exports = __toCommonJS(index_exports);
44
44
 
45
45
  // src/version.ts
46
- var SDK_VERSION = "0.24.0";
46
+ var SDK_VERSION = "0.26.0";
47
47
 
48
48
  // src/events.ts
49
49
  var EVENT_WIRE_VERSION = 1;
@@ -94,6 +94,10 @@ var ERROR_KINDS = [
94
94
  // The server cannot resolve this device's subscriber (corrupt merge
95
95
  // chain, backend SUBSCRIBER_UNRESOLVABLE). Terminal: not retryable.
96
96
  "SubscriberUnresolvable",
97
+ // The server refused the identity token identify() sent (backend
98
+ // IDENTITY_TOKEN_INVALID, 401): expired, or minted for another user,
99
+ // project or environment. Not retryable: identify again with a fresh token.
100
+ "IdentityTokenInvalid",
97
101
  "PurchaseCanceled",
98
102
  "ProductNotAvailable",
99
103
  "AlreadyOwned",
@@ -566,8 +570,8 @@ async function call2(fn) {
566
570
  async function currentUser() {
567
571
  return call2(() => getNative().currentUser());
568
572
  }
569
- async function identify(appUserId) {
570
- return call2(() => getNative().identify(appUserId));
573
+ async function identify(appUserId, identityToken) {
574
+ return call2(() => getNative().identify(appUserId, identityToken));
571
575
  }
572
576
  async function logOut() {
573
577
  return call2(() => getNative().logOut());