-
-
Notifications
You must be signed in to change notification settings - Fork 636
Exception in _handleCardChanged #2265
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
| try { | ||
| final map = Map<String, dynamic>.from(arguments); | ||
| final update = CardFieldInputDetails.fromJson( | ||
| Map<String, dynamic>.from(map['card']), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see this nesting is still necesarry tested it with latest sdk on android
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the map doesn't have the 'card' value, it creates an exception and crashes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does the UI works for you?.
We had to fork the package in PROD as it was throwing an eception
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tested both android and ios and for the ui works. Can you give me some more details of the version of the package that you are using?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry I've been very busy, I'll send a demo ASAP.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
card is not a valid value in the map
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.


Fix: Revert card parsing logic in _handleCardChanged
This PR reverts the changes made to the input parsing logic in card_field.dart. The arguments map does not contain a nested 'card' key inside it.
Instead of incorrectly attempting to extract map['card'], this change reverts to passing the entire map directly to CardFieldInputDetails.fromJson.