razorpay / razorpay-flutter

Razorpay Flutter Plugin
MIT License
106 stars 144 forks source link

type 'String' is not a subtype of type 'Map<dynamic, dynamic>?' in type cast #335

Open 0xtimsb opened 1 year ago

0xtimsb commented 1 year ago

Description

PaymentFailureResponse.fromMap (razorpay_flutter.dart:150) Razorpay._handleResult (razorpay_flutter.dart:72) Razorpay._resync (razorpay_flutter.dart:107)

Flutter Version :

3.10.5

Xcode Version :

14.3.1

Cocoapod Version :

Steps To Reproduce

  1. Crash occurs while opening razorpay.

Expected Results

Should not crash.

alok2811 commented 9 months ago

Any solution for it

richanshah commented 9 months ago

any solution?

LogicKahanHai commented 8 months ago

Any solution still?

mvharikrishnan commented 5 months ago

I have faced this issue while iam passing wrong API key through options, after when i corrected the key this was resolved.

vishal-nellsys commented 4 months ago

The issue is very simple I guess, See we are passing options in Map where key field is required. The first possible issue will be with MAP. Please check correct map format. The second possible issue is.. I guess is from API key. Check once. The third issue that I got in my integration was 'order_id' if the order id is expired or incorrect or trns declined then it will not work again.

If you want to check/cnf your issue then please remove all key-pairs except api key and try once again.