Open nafiskabbo opened 1 year ago
We are also facing similar issue in our app onBackpress
=== Stacktrace ===
Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.webkit.WebView.loadUrl(java.lang.String)' on a null object reference at com.razorpay.BaseRazorpay.finish(:16) at com.razorpay.OtpelfBaseRazorpay.finish(:16) at com.razorpay.BaseRazorpay$4.run(:45) at android.app.Activity.runOnUiThread(Activity.java:7258) at com.razorpay.BaseRazorpay.oncomplete(:7) at com.razorpay.BaseRazorpay.onBackPressed(:18)
We are also facing similar issue in our app. Please help in fixing this, I think Razorpay SDK is handling all activity results whereas it should only handle Razorpay request codes only.
Attempt to invoke virtual method 'void android.webkit.WebView.loadUrl(java.lang.String)' on a null object reference at com.razorpay.BaseRazorpay.finish(BaseRazorpay.java:1141) at com.razorpay.OtpelfBaseRazorpay.finish(OtpelfBaseRazorpay.java:69) at com.razorpay.BaseRazorpay$4.run(BaseRazorpay.java:1044) at android.app.Activity.runOnUiThread(Activity.java:7412) at com.razorpay.BaseRazorpay.oncomplete(BaseRazorpay.java:1033) at com.razorpay.BaseRazorpay.onActivityResult(BaseRazorpay.java:1478) at com.niyotail.consumer.ui.main.MainActivity.onActivityResult(MainActivity.kt:1239) at android.app.Activity.dispatchActivityResult(Activity.java:8731) at android.app.ActivityThread.deliverResults(ActivityThread.java:5648)
In my release app in play store, my app is crashing because of this error "com.razorpay.BaseRazorpay.finish (BaseRazorpay.java:1145)"
Error Logs and Reasons: Fatal Exception: java.lang.RuntimeException Failure delivering result ResultInfo{who=null, request=158, result=0, data=null} to activity {ActivityName}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.webkit.WebView.loadUrl(java.lang.String)' on a null object reference
-- Logcat Caused by java.lang.NullPointerException Attempt to invoke virtual method 'void android.webkit.WebView.loadUrl(java.lang.String)' on a null object reference com.razorpay.BaseRazorpay.finish (BaseRazorpay.java:1145) com.razorpay.OtpelfBaseRazorpay.finish (OtpelfBaseRazorpay.java:69) com.razorpay.BaseRazorpay$4.run (BaseRazorpay.java:1048) android.app.Activity.runOnUiThread (Activity.java:7074) com.razorpay.BaseRazorpay.oncomplete (BaseRazorpay.java:1037) com.razorpay.BaseRazorpay.onActivityResult (BaseRazorpay.java:1424)