react-native-mapp-plugin 1.3.1 → 1.3.2

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.
Files changed (3) hide show
  1. package/CHANGELOG.md +14 -2
  2. package/Mapp.js +22 -19
  3. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,4 +1,8 @@
1
- # Version 1.4.0
1
+ # Version 1.3.2
2
+ - Resolved an issue introduced in version 1.3.1 where changes to the setAlias function declaration caused compatibility problems. The function has been updated to ensure backward compatibility.
3
+
4
+ # Version 1.3.1
5
+ *** Features ***
2
6
  - Updated react native version to 0.81.4
3
7
  - Updated Gradle to version 8.14.2
4
8
  - android minSdk updated to version 24
@@ -6,4 +10,12 @@
6
10
 
7
11
  ### Android requrements
8
12
  * minimum required node version is 20.19.4
9
- * minimum requred Gradle version 8.14.2
13
+ * minimum requred Gradle version 8.14.2
14
+
15
+ ### iOS Requirements
16
+
17
+ * Additional flag needs to be added under the buildSettings -> OTHER_CPLUSPLUSFLAGS
18
+ -DFOLLY_CFG_NO_COROUTINES=1,
19
+ -DFOLLY_HAVE_CLOCK_GETTIME=1
20
+ * Mapp SDK 6.0.10 -> 6.1.0
21
+ * Mapp Geolocation -> 6.0.7
package/Mapp.js CHANGED
@@ -86,19 +86,14 @@ export class Mapp {
86
86
  * Sets user alias
87
87
  *
88
88
  * @param alias
89
- */
90
- static setAlias(alias: string): Promise<Boolean> {
91
- return RNMappPluginModule.setAlias(alias);
92
- }
93
-
94
- /**
95
- * Sets user alias
96
- *
97
- * @param alias
98
89
  * @param resendAttributes
99
90
  */
100
- static setAlias(alias: string, resendAttributes: bool): Promise<Boolean> {
101
- return RNMappPluginModule.setAliasWithResend(alias, resendAttributes);
91
+ static setAlias(alias: string, resendAttributes: boolean): Promise<Boolean> {
92
+ if (resendAttributes !== undefined && resendAttributes !== null) {
93
+ return RNMappPluginModule.setAliasWithResend(alias, resendAttributes);
94
+ } else {
95
+ return RNMappPluginModule.setAlias(alias);
96
+ }
102
97
  }
103
98
 
104
99
  /**
@@ -215,7 +210,7 @@ export class Mapp {
215
210
  }
216
211
  }
217
212
 
218
- /**
213
+ /**
219
214
  * Set Custom Attributes
220
215
  *
221
216
  */
@@ -223,11 +218,11 @@ export class Mapp {
223
218
  return RNMappPluginModule.setAttributes(attributes);
224
219
  }
225
220
 
226
- /**
221
+ /**
227
222
  * Get Custom Attributes
228
223
  *
229
224
  */
230
- static getAttributes(attributes: array): Promise<Object> {
225
+ static getAttributes(attributes: array): Promise<Object> {
231
226
  return RNMappPluginModule.getAttributes(attributes);
232
227
  }
233
228
 
@@ -326,13 +321,21 @@ export class Mapp {
326
321
  return RNMappPluginModule.stopGeoFencing();
327
322
  }
328
323
 
329
- static fetchLatestInboxMessage(): Promise<any>{
324
+ static fetchLatestInboxMessage(): Promise<any> {
330
325
  if (Platform.OS == "ios") {
331
- print("fatch latest message for iOS part")
326
+ print("fatch latest message for iOS part");
332
327
  RNMappPluginModule.fetchLatestInboxMessage();
333
- this.addInboxMessagesListener(messages => {
334
- print("message arrived ", messages, " length", messages[messages.length - 1])
335
- messages.sort((message1, message2) => message1["template_id"] > message2["template_id"]);
328
+ this.addInboxMessagesListener((messages) => {
329
+ print(
330
+ "message arrived ",
331
+ messages,
332
+ " length",
333
+ messages[messages.length - 1]
334
+ );
335
+ messages.sort(
336
+ (message1, message2) =>
337
+ message1["template_id"] > message2["template_id"]
338
+ );
336
339
  alert(JSON.stringify(messages[0]));
337
340
  return JSON.stringify(messages[0]);
338
341
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-mapp-plugin",
3
- "version": "1.3.1",
3
+ "version": "1.3.2",
4
4
  "description": "Mapp SDK for React Native.",
5
5
  "main": "index.js",
6
6
  "keywords": [