apps-sdk 1.0.124 → 1.0.126

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "apps-sdk",
3
- "version": "1.0.124",
3
+ "version": "1.0.126",
4
4
  "description": "Apps SDK",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -130,7 +130,7 @@ class PayWall extends React.Component {
130
130
  }
131
131
  }
132
132
 
133
- if (this.paywallData && data.id && data.id.length > 0 && this.paywallData.products_id && this.paywallData.products_id.length > 0) {
133
+ if (this.paywallData && data.id && data.id.length > 0) {
134
134
  Networking.sendEvent('action', 'cta', {product_id: data.id});
135
135
  let subscribed = PayWallLogic.executePurchase(data.id, this.hideSpinner, this.hidePayWall).then((subscribed) => {
136
136
  console.log('subscription result: ', subscribed);
@@ -5,6 +5,7 @@ import * as Localization from 'expo-localization'
5
5
  import Storage from './Storage';
6
6
  import Networking from './Networking';
7
7
  import * as config from "../../config";
8
+ import storage from "./Storage";
8
9
 
9
10
  class Session {
10
11
  sessionData = {};
@@ -24,6 +25,11 @@ class Session {
24
25
  await this.checkFirstOpen();
25
26
  }
26
27
 
28
+ setConfigEndpoint = (endpoint) => {
29
+ config.DEBUG_MODE && console.debug("setInitEndpoint - endpoint: ", endpoint);
30
+ config.ENDPOINTS.CONFIG = endpoint;
31
+ }
32
+
27
33
  initSession = async () => {
28
34
  config.DEBUG_MODE && console.debug("initSession");
29
35
  await Networking.sendEvent(config.EVENT_TYPES.OTHER, 'init_session');
@@ -154,7 +160,7 @@ class Session {
154
160
  }
155
161
 
156
162
  getAdjustIDFA = () => {
157
- return this.sessionData.adjust.idfa || '';
163
+ return this.sessionData.adjust.idfa || storage.getData('adjustIDFA') || '';
158
164
  }
159
165
 
160
166
  setAdjustGoogleAdid = (googleAdid) => {
package/types/index.d.ts CHANGED
@@ -34,6 +34,7 @@ declare module 'apps-sdk' {
34
34
  isDevUser: boolean;
35
35
  forcedUpdate: boolean;
36
36
  init(): Promise<void>;
37
+ setConfigEndpoint(endpoint: string): void;
37
38
  initSession(): Promise<void>;
38
39
  storeSessionStructure(): Promise<void>;
39
40
  checkFirstOpen(): Promise<void>;