You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
The error being thrown if the user closes customer sheet without choosing another card, not already selected.
To Reproduce
Steps to reproduce the behavior:
Open customer sheet
Add card
Confirm and close
Open sheet again
Just close
Expected behavior
CustomerSheetResult or null is returned
Actual behavior
Stacktrace
type 'Null' is not a subtype of type 'String' in type cast
type 'Null' is not a subtype of type 'String' in type cast
#0 _$$StripeErrorGenericImplFromJson (package:stripe_platform_interface/src/models/errors.g.dart:12:32)
#1 new _$StripeErrorGenericImpl.fromJson (package:stripe_platform_interface/src/models/errors.freezed.dart:123:7)
#2 _$StripeErrorFromJson (package:stripe_platform_interface/src/models/errors.freezed.dart:18:10)
#3 new StripeError.fromJson (package:stripe_platform_interface/src/models/errors.dart:26:7)
#4 _$$CustomerSheetResultImplFromJson (package:stripe_platform_interface/src/models/customer_sheet.g.dart:115:13)
#5 new _$CustomerSheetResultImpl.fromJson (package:stripe_platform_interface/src/models/customer_sheet.freezed.dart:973:7)
#6 _$CustomerSheetResultFromJson (package:stripe_platform_interface/src/models/customer_sheet.freezed.dart:804:31)
#7 new CustomerSheetResult.fromJson (package:stripe_platform_interface/src/models/customer_sheet.dart:96:7)
#8 MethodChannelStripe._parseCustomerSheetResult (package:stripe_platform_interface/src/method_channel_stripe.dart:357:36)
#9 MethodChannelStripe.presentCustomerSheet (package:stripe_platform_interface/src/method_channel_stripe.dart:277:12)
<asynchronous suspension>
#10 _SetupFuturePaymentScreenState._handleSavePress (package:client_app/src/feature/order/widget/test_stripe.dart:140:22)
<asynchronous suspension>
#11 _LoadingButtonState._loadFuture (package:client_app/src/feature/order/widget/widgets/loading_button.dart:50:7)
<asynchronous suspension>
Sample
```
Future _handleSavePress() async {
if (_card == null) {
return;
}
try {
// 1. Create setup intent on backend
final stripeConfig = await _createSetupIntentOnBackend(_email);
Describe the bug
The error being thrown if the user closes customer sheet without choosing another card, not already selected.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
CustomerSheetResult or null is returned
Actual behavior
Stacktrace
Sample
}
The text was updated successfully, but these errors were encountered: