Skip to content

Commit 09b25c9

Browse files
authored
Merge pull request #2 from Flutterwave/master
Update
2 parents f0daea7 + 7c6483a commit 09b25c9

File tree

8 files changed

+16
-13
lines changed

8 files changed

+16
-13
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ The minimum supported SDK version is 15
2828
**Step 2.** Add the dependency
2929

3030
dependencies {
31-
implementation 'com.github.Flutterwave:rave-android:1.0.33'
31+
implementation 'com.github.Flutterwave:rave-android:1.0.35'
3232
}
3333

3434
**Step 3.** Add the required permission

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ buildscript {
66
google()
77
}
88
dependencies {
9-
classpath 'com.android.tools.build:gradle:3.2.0'
10-
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5'
9+
classpath 'com.android.tools.build:gradle:3.2.1'
10+
classpath 'com.github.dcendents:android-maven-gradle-plugin:2.0'
1111
// NOTE: Do not place your application dependencies here; they belong
1212
// in the individual module build.gradle files
1313
}

raveandroid/build.gradle

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ group = 'com.github.flutterwave'
44

55
android {
66
compileSdkVersion 25
7-
buildToolsVersion '28.0.2'
87

98
defaultConfig {
109
minSdkVersion 15
@@ -31,10 +30,10 @@ dependencies {
3130
implementation 'com.android.support:appcompat-v7:25.4.0'
3231
implementation 'com.android.support:design:25.4.0'
3332
implementation 'com.android.support:support-v4:25.4.0'
34-
implementation 'com.squareup.picasso:picasso:2.5.2'
33+
implementation 'com.squareup.picasso:picasso:2.71828'
3534
implementation 'com.squareup.retrofit2:retrofit:2.4.0'
3635
implementation 'com.squareup.retrofit2:converter-gson:2.3.0'
37-
implementation 'com.squareup.okhttp3:logging-interceptor:3.8.0'
36+
implementation 'com.squareup.okhttp3:logging-interceptor:3.9.1'
3837
implementation 'org.parceler:parceler-api:1.1.9'
3938
annotationProcessor 'org.parceler:parceler:1.1.9'
4039
implementation 'com.squareup.retrofit2:converter-scalars:2.1.0'

raveandroid/src/main/java/com/flutterwave/raveandroid/Payload.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@ public void setPin(String pin) {
312312

313313
private String pin;
314314

315-
private String redirect_url = "https://rave-webhook.herokuapp.com/receivepayment";
315+
private String redirect_url = RaveConstants.RAVE_3DS_CALLBACK;
316316

317317
public String getPBFSecKey() {
318318
return PBFSecKey;

raveandroid/src/main/java/com/flutterwave/raveandroid/RaveConstants.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ public class RaveConstants {
2222
public static String NOAUTH_INTERNATIONAL = "NOAUTH_INTERNATIONAL";
2323
public static String RAVEPAY = "ravepay";
2424
public static String RAVE_PARAMS = "raveparams";
25+
public static String RAVE_3DS_CALLBACK = "https://rave-webhook.herokuapp.com/receivepayment";
2526
public static int RAVE_REQUEST_CODE = 4199;
2627
public static int MANUAL_CARD_CHARGE = 403;
2728
public static int TOKEN_CHARGE = 24;

raveandroid/src/main/java/com/flutterwave/raveandroid/RavePayInitializer.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ public RavePayInitializer(String email, double amount, String publicKey,
5454
this.lName = lName;
5555
this.withAccount = withAccount;
5656
this.withGHMobileMoney = withGHMobileMoney;
57+
this.withUgMobileMoney = withUgMobileMoney;
5758
this.withMpesa = withMpesa;
5859
this.withCard = withCard;
5960
this.withAch = withAch;

raveandroid/src/main/java/com/flutterwave/raveandroid/WebFragment.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public void onPageFinished(WebView view, String url) {
8585
showProgressIndicator(false);
8686

8787
Log.d("finished URLS", url);
88-
if (url.contains("/complete") || url.contains("submitting_mock_form")) {
88+
if (url.contains(RaveConstants.RAVE_3DS_CALLBACK)) {
8989
goBack();
9090
}
9191
}

raveandroid/src/main/java/com/flutterwave/raveandroid/account/AccountFragment.java

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -230,15 +230,17 @@ private void validateDetails() {
230230
dob = dob.replace("/", "");
231231
}
232232
}
233-
}
234233

235-
if(selectedBank.getBankcode().equals("033")){
236-
if(bvn.length() != 11){
237-
rave_bvnTil.setError("Enter a valid BVN");
238-
valid = false;
234+
if(selectedBank.getBankcode().equals("033")){
235+
if(bvn.length() != 11){
236+
rave_bvnTil.setError("Enter a valid BVN");
237+
valid = false;
238+
}
239239
}
240240
}
241241

242+
243+
242244
if (valid) {
243245
String txRef = ravePayInitializer.getTxRef();
244246

0 commit comments

Comments
 (0)