Skip to content

Commit 96a375b

Browse files
authored
Merge pull request #206 from square/charmis/upgrade_version_IAP_1.6.1
upgrade version to 1.6.1
2 parents 2480d6b + 2b1aef6 commit 96a375b

12 files changed

Lines changed: 416 additions & 348 deletions

File tree

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
## Changelog
22

3+
### v1.7.3 April 05, 2023
4+
5+
* Upgrade IAP SDK for Android `1.6.2` and for iOS `1.6.1`.
6+
* An important update to SquareBuyerVerificationSDK that mitigates the risk of declining 3-D Secure (3DS) payments for ios.
7+
* Various bug fixes.
8+
39
### v1.7.2 May 23, 2022
410

511
* Upgrade IAP SDK to `1.5.6`.

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
The In-App Payments plugin for Square [In-App Payments SDK] is a wrapper for the native Android and iOS SDKs and
77
supports the following native In-App Payments SDK versions:
88

9-
* iOS: `1.5.6`
10-
* Android: `1.5.6`
9+
* iOS: `1.6.1`
10+
* Android: `1.6.2`
1111

1212
## Additional documentation
1313

RNSquareInAppPayments.podspec

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Pod::Spec.new do |s|
33
s.name = "RNSquareInAppPayments"
4-
s.version = "1.5.6"
4+
s.version = "1.6.1"
55
s.summary = "React Native plugin for Square's In-App Payments SDK"
66
s.description = <<-DESC
77
An open source React Native plugin for calling Square’s native In-App Payments SDK to take in-app payments on iOS and Android.
@@ -22,8 +22,8 @@ Pod::Spec.new do |s|
2222
s.dependency 'SquareInAppPaymentsSDK', $sqipVersion
2323
s.dependency 'SquareBuyerVerificationSDK', $sqipVersion
2424
else
25-
s.dependency 'SquareInAppPaymentsSDK', '1.5.6'
26-
s.dependency 'SquareBuyerVerificationSDK', '1.5.6'
25+
s.dependency 'SquareInAppPaymentsSDK', '1.6.1'
26+
s.dependency 'SquareBuyerVerificationSDK', '1.6.1'
2727
end
2828

2929
end

android/build.gradle

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,25 @@
11

22
buildscript {
33
repositories {
4-
jcenter()
54
google()
5+
mavenCentral()
66
}
77

88
dependencies {
9-
classpath 'com.android.tools.build:gradle:4.2.2'
9+
classpath 'com.android.tools.build:gradle:7.2.2'
1010
}
1111
}
1212

1313
apply plugin: 'com.android.library'
1414

15-
def MIN_IAP_SDK_VERSION = '1.5.6'
15+
def MIN_IAP_SDK_VERSION = '1.6.2'
1616

1717
android {
18-
compileSdkVersion 30
18+
compileSdkVersion 33
1919

2020
defaultConfig {
2121
minSdkVersion 24
22-
targetSdkVersion 30
22+
targetSdkVersion 33
2323
versionCode 1
2424
versionName "1.0"
2525
}
@@ -35,7 +35,7 @@ android {
3535
rootProject.allprojects {
3636
repositories {
3737
google()
38-
maven {
38+
maven {
3939
url 'https://sdk.squareup.com/public/android'
4040
}
4141
}

docs/get-started.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,16 @@ to download In-App Payments SDK automatically by following the steps below.
113113
```bash
114114
pod install
115115
```
116-
116+
1. Add an In-App Payments SDK build phase:
117+
1. Open the **Xcode** project for your application.
118+
1. In the **Build Phases** tab for your application target, click the **+**
119+
button at the top of the pane.
120+
1. Select **New Run Script Phase**.
121+
1. Paste the following into the editor panel of the new run script:
122+
```
123+
FRAMEWORKS="${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}"
124+
"${FRAMEWORKS}/SquareInAppPaymentsSDK.framework/setup"
125+
```
117126
## Step 4: Configure your Android project
118127
119128
1. Open `android/build.gradle` and set your `minSdkVersion` to `21` or greater.

docs/versioning.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,23 @@ You can override the default In-App Payments SDK versions by following this guid
1717
$sqipVersion = '1.7.1'
1818
```
1919

20-
1. Remove the `ios/Podfile.lock` and build your project again.
20+
2. Remove the `ios/Podfile.lock` and build your project again.
2121
```bash
2222
cd ios
2323
rm Podfile.lock
2424
pod install
2525
```
26+
3. Add build phase to setup the SquareInAppPaymentsSDK and/or SquareBuyerVerificationSDK framework
27+
After adding the framework using any of the above methods, follow the below instructions to complete the setup.
28+
29+
On your application targets’ Build Phases settings tab, click the + icon and choose New Run Script Phase. Create a Run Script in which you specify your shell (ex: /bin/sh), add the following contents to the script area below the shell:
30+
```bash
31+
FRAMEWORKS="${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}"
32+
"${FRAMEWORKS}/SquareInAppPaymentsSDK.framework/setup"
33+
```
34+
35+
Note : If you are using SquareBuyerVerificationSDK earlier than version 1.6.1 for iOS, please upgrade to 1.6.1 so that the SDK can process 3DS-enabled payments. The SDK will decline 3DS-enabled payments made after March 31, 2023 if the SDK version is earlier than 1.6.1.
36+
2637

2738
## Android
2839

react-native-in-app-payments-quickstart/android/app/build.gradle

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,9 @@ android {
167167
proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
168168
}
169169
}
170+
buildFeatures {
171+
viewBinding true
172+
}
170173

171174
// applicationVariants are e.g. debug, release
172175
applicationVariants.all { variant ->
@@ -190,7 +193,9 @@ dependencies {
190193
//noinspection GradleDynamicVersion
191194
implementation "com.facebook.react:react-native:+" // From node_modules
192195

193-
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.0.0"
196+
implementation "androidx.core:core-ktx:1.9.0"
197+
implementation 'androidx.appcompat:appcompat:1.6.1'
198+
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"
194199

195200
debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") {
196201
exclude group:'com.facebook.fbjni'

react-native-in-app-payments-quickstart/android/build.gradle

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,16 @@
22

33
buildscript {
44
ext {
5-
buildToolsVersion = "30.0.3"
5+
buildToolsVersion = "33.0.2"
66
minSdkVersion = 24
7-
compileSdkVersion = 32
8-
targetSdkVersion = 32
7+
compileSdkVersion = 33
8+
targetSdkVersion = 33
99
ndkVersion = "20.1.5948944"
10-
sqipVersion="1.5.6"
10+
sqipVersion="1.6.2"
1111
kotlin_version = '1.7.10'
1212
}
1313
repositories {
1414
google()
15-
jcenter()
1615
mavenCentral()
1716
}
1817
dependencies {
@@ -44,9 +43,18 @@ allprojects {
4443
// Android JSC is installed from npm
4544
url("$rootDir/../node_modules/jsc-android/dist")
4645
}
46+
mavenCentral {
47+
// We don't want to fetch react-native from Maven Central as there are
48+
// older versions over there.
49+
content {
50+
excludeGroup "com.facebook.react"
51+
}
52+
}
4753
google()
48-
jcenter()
4954
mavenCentral()
5055
maven { url 'https://www.jitpack.io' }
56+
maven {
57+
url "https://maven.google.com"
58+
}
5159
}
5260
}

react-native-in-app-payments-quickstart/android/gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,5 @@ android.useAndroidX=true
2020
android.enableJetifier=true
2121

2222
# Version of flipper SDK to use with React Native
23-
FLIPPER_VERSION=0.75.1
23+
FLIPPER_VERSION=0.99.0
2424
org.gradle.jvmargs=-Xmx1536M --add-exports=java.base/sun.nio.ch=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.lang.reflect=ALL-UNNAMED --add-opens=java.base/java.io=ALL-UNNAMED --add-exports=jdk.unsupported/sun.misc=ALL-UNNAMED

react-native-in-app-payments-quickstart/ios/Podfile.lock

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -285,12 +285,12 @@ PODS:
285285
- React-perflogger (= 0.68.0)
286286
- RNGestureHandler (2.9.0):
287287
- React-Core
288-
- RNSquareInAppPayments (1.5.6):
288+
- RNSquareInAppPayments (1.6.1):
289289
- React
290-
- SquareBuyerVerificationSDK (= 1.5.6)
291-
- SquareInAppPaymentsSDK (= 1.5.6)
292-
- SquareBuyerVerificationSDK (1.5.6)
293-
- SquareInAppPaymentsSDK (1.5.6)
290+
- SquareBuyerVerificationSDK (= 1.6.1)
291+
- SquareInAppPaymentsSDK (= 1.6.1)
292+
- SquareBuyerVerificationSDK (1.6.1)
293+
- SquareInAppPaymentsSDK (1.6.1)
294294
- Yoga (1.14.0)
295295

296296
DEPENDENCIES:
@@ -437,11 +437,11 @@ SPEC CHECKSUMS:
437437
React-runtimeexecutor: 9b1304f48e344c55bb3c36e13bf11461cb4da5d8
438438
ReactCommon: fab89a13b52f1ac42b59a0e4b4f76f21aea9eebe
439439
RNGestureHandler: 071d7a9ad81e8b83fe7663b303d132406a7d8f39
440-
RNSquareInAppPayments: 3b4f6e96d1575c856255de00b27f36e702db45d4
441-
SquareBuyerVerificationSDK: d1253b4ed9a1226dc8d4b5bc800cd47886768078
442-
SquareInAppPaymentsSDK: 99476a38e643d4f2ebf86c0c2167752553683481
440+
RNSquareInAppPayments: ede813773dc54376c765fdf6ca77a68ae763ac99
441+
SquareBuyerVerificationSDK: f200ad95adc08bdefc80619cfa462f0451a7c436
442+
SquareInAppPaymentsSDK: 44371b3788070e74b43009ab90649455277653b4
443443
Yoga: 6671cf077f614314c22fd09ddf87d7abeee64e96
444444

445-
PODFILE CHECKSUM: 1d41a1d217b2c7cc0e90c8b7bf895c82a760b977
445+
PODFILE CHECKSUM: 02a139017a637df9e67a6a8dae0046dd7bb21bfa
446446

447-
COCOAPODS: 1.11.3
447+
COCOAPODS: 1.12.0

0 commit comments

Comments
 (0)