mirror of
https://github.com/streetwriters/notesnook.git
synced 2025-12-16 19:57:52 +01:00
mobile: iap upgrade (#1361)
* mobile: upgrade iap to v7 * mobile: update build.gradle
This commit is contained in:
@@ -309,7 +309,8 @@ const subscriptions = {
|
||||
subscription = _subscriptions.length > 0 ? _subscriptions[0] : null;
|
||||
}
|
||||
if (subscription) {
|
||||
await RNIap.finishTransactionIOS(subscription.transactionId);
|
||||
|
||||
await RNIap.finishTransaction(subscription.transactionId);
|
||||
await RNIap.clearTransactionIOS();
|
||||
await subscriptions.remove(subscription.transactionId);
|
||||
}
|
||||
|
||||
@@ -164,6 +164,7 @@ android {
|
||||
versionName getNpmVersion()
|
||||
testBuildType System.getProperty('testBuildType', 'debug')
|
||||
testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
|
||||
missingDimensionStrategy "store", "play"
|
||||
buildConfigField "boolean", "IS_NEW_ARCHITECTURE_ENABLED", isNewArchitectureEnabled().toString()
|
||||
if (isNewArchitectureEnabled()) {
|
||||
// We configure the NDK build only if you decide to opt-in for the New Architecture.
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
"react-native-gesture-handler": "^2.5.0",
|
||||
"react-native-get-random-values": "^1.7.0",
|
||||
"react-native-html-to-pdf-lite": "^0.9.1",
|
||||
"react-native-iap": "5.2.14",
|
||||
"react-native-iap": "7.5.6",
|
||||
"react-native-image-picker": "4.1.2",
|
||||
"react-native-keychain": "4.0.5",
|
||||
"react-native-mmkv-storage": "^0.8.0",
|
||||
|
||||
22
apps/mobile/package-lock.json
generated
22
apps/mobile/package-lock.json
generated
@@ -87,7 +87,7 @@
|
||||
"react-native-get-random-values": "^1.7.0",
|
||||
"react-native-gzip": "1.0.0",
|
||||
"react-native-html-to-pdf-lite": "^0.9.1",
|
||||
"react-native-iap": "5.2.14",
|
||||
"react-native-iap": "7.5.6",
|
||||
"react-native-image-picker": "4.1.2",
|
||||
"react-native-keychain": "4.0.5",
|
||||
"react-native-mmkv-storage": "^0.8.0",
|
||||
@@ -18310,14 +18310,14 @@
|
||||
"integrity": "sha512-HeD7YDHO7pL/4n/lAJCo1L4x0+JeKiME95B8jwH8lGBzkcHNX1hmb+CFM9SGSI//YtUL/a2sQjjkkoh6Cf7GNw=="
|
||||
},
|
||||
"node_modules/react-native-iap": {
|
||||
"version": "5.2.14",
|
||||
"resolved": "https://registry.npmjs.org/react-native-iap/-/react-native-iap-5.2.14.tgz",
|
||||
"integrity": "sha512-knxdKfVZjhkIhLTwTqA9GKZ5/4oLuRfriKsLINFWCSiVJ/NOB/kEI6m5w3L5ZvIf2c2Bv+a6mH2sYSNvouB2Tg==",
|
||||
"version": "7.5.6",
|
||||
"resolved": "https://registry.npmjs.org/react-native-iap/-/react-native-iap-7.5.6.tgz",
|
||||
"integrity": "sha512-ua+KTq7NO+/Rw+S9cGDZizR45AdmpQ0LEx9gSubbRD3f5KSTp91mEMHgdyVcqUcxiBuVgRTfv3zy9mbPEdo8Mg==",
|
||||
"dependencies": {
|
||||
"dooboolab-welcome": "^1.2.0"
|
||||
"dooboolab-welcome": "1.3.2"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"react": "*",
|
||||
"react": ">=16.13.1",
|
||||
"react-native": ">=0.54"
|
||||
}
|
||||
},
|
||||
@@ -24309,7 +24309,7 @@
|
||||
"react-native-get-random-values": "^1.7.0",
|
||||
"react-native-gzip": "1.0.0",
|
||||
"react-native-html-to-pdf-lite": "^0.9.1",
|
||||
"react-native-iap": "5.2.14",
|
||||
"react-native-iap": "7.5.6",
|
||||
"react-native-image-picker": "4.1.2",
|
||||
"react-native-keychain": "4.0.5",
|
||||
"react-native-mmkv-storage": "^0.8.0",
|
||||
@@ -35021,11 +35021,11 @@
|
||||
"integrity": "sha512-HeD7YDHO7pL/4n/lAJCo1L4x0+JeKiME95B8jwH8lGBzkcHNX1hmb+CFM9SGSI//YtUL/a2sQjjkkoh6Cf7GNw=="
|
||||
},
|
||||
"react-native-iap": {
|
||||
"version": "5.2.14",
|
||||
"resolved": "https://registry.npmjs.org/react-native-iap/-/react-native-iap-5.2.14.tgz",
|
||||
"integrity": "sha512-knxdKfVZjhkIhLTwTqA9GKZ5/4oLuRfriKsLINFWCSiVJ/NOB/kEI6m5w3L5ZvIf2c2Bv+a6mH2sYSNvouB2Tg==",
|
||||
"version": "7.5.6",
|
||||
"resolved": "https://registry.npmjs.org/react-native-iap/-/react-native-iap-7.5.6.tgz",
|
||||
"integrity": "sha512-ua+KTq7NO+/Rw+S9cGDZizR45AdmpQ0LEx9gSubbRD3f5KSTp91mEMHgdyVcqUcxiBuVgRTfv3zy9mbPEdo8Mg==",
|
||||
"requires": {
|
||||
"dooboolab-welcome": "^1.2.0"
|
||||
"dooboolab-welcome": "1.3.2"
|
||||
}
|
||||
},
|
||||
"react-native-image-pan-zoom": {
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
diff --git a/node_modules/react-native-iap/android/src/main/java/com/dooboolab/RNIap/RNIapModule.java b/node_modules/react-native-iap/android/src/main/java/com/dooboolab/RNIap/RNIapModule.java
|
||||
index 0a77a6a..43df636 100644
|
||||
--- a/node_modules/react-native-iap/android/src/main/java/com/dooboolab/RNIap/RNIapModule.java
|
||||
+++ b/node_modules/react-native-iap/android/src/main/java/com/dooboolab/RNIap/RNIapModule.java
|
||||
@@ -74,6 +74,16 @@ public class RNIapModule extends ReactContextBaseJavaModule implements Purchases
|
||||
}
|
||||
};
|
||||
|
||||
+ @ReactMethod
|
||||
+ public void addListener(String eventName) {
|
||||
+ // Keep: Required for RN built in Event Emitter Calls.
|
||||
+ }
|
||||
+
|
||||
+ @ReactMethod
|
||||
+ public void removeListeners(double count) {
|
||||
+ // Keep: Required for RN built in Event Emitter Calls.
|
||||
+ }
|
||||
+
|
||||
public RNIapModule(ReactApplicationContext reactContext) {
|
||||
super(reactContext);
|
||||
this.reactContext = reactContext;
|
||||
Reference in New Issue
Block a user