Skip to content
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

fix #1390 payment intents with unknown confirm method. #1412

Merged
merged 1 commit into from
Sep 25, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,8 @@ class MethodChannelStripe extends StripePlatform {
}

@override
Future<SetupIntent> handleNextActionForSetupIntent(String setupIntentClientSecret,
Future<SetupIntent> handleNextActionForSetupIntent(
String setupIntentClientSecret,
{String? returnURL}) async {
final result = await _methodChannel
.invokeMapMethod<String, dynamic>('handleNextAction', {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// coverage:ignore-file

Check warning on line 1 in packages/stripe_platform_interface/lib/src/models/aubecs_form.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

Filename: packages/stripe_platform_interface/lib/src/models/aubecs_form.freezed.dart

"aubecs" in the filename is a typo. Did you mean "because"?

Check warning on line 1 in packages/stripe_platform_interface/lib/src/models/aubecs_form.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

Filename: packages/stripe_platform_interface/lib/src/models/aubecs_form.freezed.dart

"freezed" in the filename is a typo. Did you mean "freezes"?
// GENERATED CODE - DO NOT MODIFY BY HAND
// ignore_for_file: type=lint
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark
Expand Down Expand Up @@ -56,17 +56,17 @@
@useResult
$Res call(
{@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textColor,
Color? textColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textErrorColor,
Color? textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? placeholderColor,
Color? placeholderColor,
int? fontSize,
int? borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? backgroundColor,
Color? backgroundColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? borderColor,
Color? borderColor,
int? borderRadius});
}

Expand Down Expand Up @@ -139,17 +139,17 @@
@useResult
$Res call(
{@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textColor,
Color? textColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textErrorColor,
Color? textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? placeholderColor,
Color? placeholderColor,
int? fontSize,
int? borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? backgroundColor,
Color? backgroundColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? borderColor,
Color? borderColor,
int? borderRadius});
}

Expand Down Expand Up @@ -216,17 +216,17 @@
class _$_AubecsFormStyle implements _AubecsFormStyle {
const _$_AubecsFormStyle(
{@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.textColor,
this.textColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.textErrorColor,
this.textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.placeholderColor,
this.placeholderColor,
this.fontSize,
this.borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.backgroundColor,
this.backgroundColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.borderColor,
this.borderColor,
this.borderRadius});

factory _$_AubecsFormStyle.fromJson(Map<String, dynamic> json) =>
Expand Down Expand Up @@ -320,17 +320,17 @@
abstract class _AubecsFormStyle implements AubecsFormStyle {
const factory _AubecsFormStyle(
{@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? textColor,
final Color? textColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? textErrorColor,
final Color? textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? placeholderColor,
final Color? placeholderColor,
final int? fontSize,
final int? borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? backgroundColor,
final Color? backgroundColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? borderColor,
final Color? borderColor,
final int? borderRadius}) = _$_AubecsFormStyle;

factory _AubecsFormStyle.fromJson(Map<String, dynamic> json) =
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// coverage:ignore-file

Check warning on line 1 in packages/stripe_platform_interface/lib/src/models/card_field_input.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

Filename: packages/stripe_platform_interface/lib/src/models/card_field_input.freezed.dart

"freezed" in the filename is a typo. Did you mean "freezes"?
// GENERATED CODE - DO NOT MODIFY BY HAND
// ignore_for_file: type=lint
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark
Expand Down Expand Up @@ -60,20 +60,20 @@
$Res call(
{int? borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? backgroundColor,
Color? backgroundColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? borderColor,
Color? borderColor,
int? borderRadius,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? cursorColor,
Color? cursorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textColor,
Color? textColor,
int? fontSize,
String? fontFamily,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textErrorColor,
Color? textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? placeholderColor});
Color? placeholderColor});
}

/// @nodoc
Expand Down Expand Up @@ -156,20 +156,20 @@
$Res call(
{int? borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? backgroundColor,
Color? backgroundColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? borderColor,
Color? borderColor,
int? borderRadius,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? cursorColor,
Color? cursorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textColor,
Color? textColor,
int? fontSize,
String? fontFamily,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textErrorColor,
Color? textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? placeholderColor});
Color? placeholderColor});
}

/// @nodoc
Expand Down Expand Up @@ -246,20 +246,20 @@
_$_CardStyleConstructor(
{this.borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.backgroundColor,
this.backgroundColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.borderColor,
this.borderColor,
this.borderRadius,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.cursorColor,
this.cursorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.textColor,
this.textColor,
this.fontSize,
this.fontFamily,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.textErrorColor,
this.textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.placeholderColor})
this.placeholderColor})
: super._();

factory _$_CardStyleConstructor.fromJson(Map<String, dynamic> json) =>
Expand Down Expand Up @@ -367,20 +367,20 @@
factory _CardStyleConstructor(
{final int? borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? backgroundColor,
final Color? backgroundColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? borderColor,
final Color? borderColor,
final int? borderRadius,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? cursorColor,
final Color? cursorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? textColor,
final Color? textColor,
final int? fontSize,
final String? fontFamily,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? textErrorColor,
final Color? textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? placeholderColor}) = _$_CardStyleConstructor;
final Color? placeholderColor}) = _$_CardStyleConstructor;
_CardStyleConstructor._() : super._();

factory _CardStyleConstructor.fromJson(Map<String, dynamic> json) =
Expand Down Expand Up @@ -472,20 +472,20 @@
@useResult
$Res call(
{@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? backgroundColor,
Color? backgroundColor,
int? borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? borderColor,
Color? borderColor,
int? borderRadius,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? cursorColor,
Color? cursorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textColor,
Color? textColor,
int? fontSize,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textErrorColor,
Color? textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? placeholderColor});
Color? placeholderColor});
}

/// @nodoc
Expand Down Expand Up @@ -563,20 +563,20 @@
@useResult
$Res call(
{@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? backgroundColor,
Color? backgroundColor,
int? borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? borderColor,
Color? borderColor,
int? borderRadius,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? cursorColor,
Color? cursorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textColor,
Color? textColor,
int? fontSize,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? textErrorColor,
Color? textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
Color? placeholderColor});
Color? placeholderColor});
}

/// @nodoc
Expand Down Expand Up @@ -647,20 +647,20 @@
class _$_CardFormStyleConstructor extends _CardFormStyleConstructor {
_$_CardFormStyleConstructor(
{@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.backgroundColor,
this.backgroundColor,
this.borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.borderColor,
this.borderColor,
this.borderRadius,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.cursorColor,
this.cursorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.textColor,
this.textColor,
this.fontSize,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.textErrorColor,
this.textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
this.placeholderColor})
this.placeholderColor})
: super._();

factory _$_CardFormStyleConstructor.fromJson(Map<String, dynamic> json) =>
Expand Down Expand Up @@ -761,20 +761,20 @@
abstract class _CardFormStyleConstructor extends CardFormStyle {
factory _CardFormStyleConstructor(
{@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? backgroundColor,
final Color? backgroundColor,
final int? borderWidth,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? borderColor,
final Color? borderColor,
final int? borderRadius,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? cursorColor,
final Color? cursorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? textColor,
final Color? textColor,
final int? fontSize,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? textErrorColor,
final Color? textErrorColor,
@JsonKey(toJson: ColorKey.toJson, fromJson: ColorKey.fromJson)
final Color? placeholderColor}) = _$_CardFormStyleConstructor;
final Color? placeholderColor}) = _$_CardFormStyleConstructor;
_CardFormStyleConstructor._() : super._();

factory _CardFormStyleConstructor.fromJson(Map<String, dynamic> json) =
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// coverage:ignore-file

Check warning on line 1 in packages/stripe_platform_interface/lib/src/models/errors.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

Filename: packages/stripe_platform_interface/lib/src/models/errors.freezed.dart

"freezed" in the filename is a typo. Did you mean "freezes"?
// GENERATED CODE - DO NOT MODIFY BY HAND
// ignore_for_file: type=lint
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark
Expand Down Expand Up @@ -117,7 +117,7 @@
const _$_StripeErrorGeneric(
{required this.message,
@JsonKey(fromJson: _dataFromJson, toJson: _dataToJson)
required this.code});
required this.code});

factory _$_StripeErrorGeneric.fromJson(Map<String, dynamic> json) =>
_$$_StripeErrorGenericFromJson(json);
Expand Down Expand Up @@ -166,7 +166,7 @@
const factory _StripeErrorGeneric(
{required final String message,
@JsonKey(fromJson: _dataFromJson, toJson: _dataToJson)
required final T code}) = _$_StripeErrorGeneric<T>;
required final T code}) = _$_StripeErrorGeneric<T>;

factory _StripeErrorGeneric.fromJson(Map<String, dynamic> json) =
_$_StripeErrorGeneric<T>.fromJson;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,9 @@ enum ConfirmationMethod {

/// Payment intent will be confirmed using the publishable key.
Automatic,

/// Unknown confirmation method.
Unknown,
}

//nextActionMap.putString("type", "urlRedirect")
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// coverage:ignore-file

Check warning on line 1 in packages/stripe_platform_interface/lib/src/models/payment_methods.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

Filename: packages/stripe_platform_interface/lib/src/models/payment_methods.freezed.dart

"freezed" in the filename is a typo. Did you mean "freezes"?
// GENERATED CODE - DO NOT MODIFY BY HAND
// ignore_for_file: type=lint
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark
Expand Down Expand Up @@ -574,24 +574,16 @@
required final bool livemode,
required final String paymentMethodType,
required final BillingDetails billingDetails,
@JsonKey(name: 'Card')
required final Card card,
@JsonKey(name: 'SepaDebit')
required final SepaDebit sepaDebit,
@JsonKey(name: 'BacsDebit')
required final BacsDebit bacsDebit,
@JsonKey(name: 'AuBecsDebit')
required final AuBecsDebit auBecsDebit,
@JsonKey(name: 'Sofort')
required final Sofort sofort,
@JsonKey(name: 'Ideal')
required final Ideal ideal,
@JsonKey(name: 'Fpx')
required final Fpx fpx,
@JsonKey(name: 'Upi')
required final Upi upi,
@JsonKey(name: 'Card') required final Card card,
@JsonKey(name: 'SepaDebit') required final SepaDebit sepaDebit,
@JsonKey(name: 'BacsDebit') required final BacsDebit bacsDebit,

Check warning on line 579 in packages/stripe_platform_interface/lib/src/models/payment_methods.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

BacsDebit

"BacsDebit" is a typo. Did you mean "CabsDebit"?

Check warning on line 579 in packages/stripe_platform_interface/lib/src/models/payment_methods.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

bacsDebit

"bacsDebit" is a typo. Did you mean "cabsDebit"?
@JsonKey(name: 'AuBecsDebit') required final AuBecsDebit auBecsDebit,

Check warning on line 580 in packages/stripe_platform_interface/lib/src/models/payment_methods.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

AuBecsDebit

"AuBecsDebit" is a typo. Did you mean "AuBecksDebit"?

Check warning on line 580 in packages/stripe_platform_interface/lib/src/models/payment_methods.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

auBecsDebit

"auBecsDebit" is a typo. Did you mean "auBecksDebit"?
@JsonKey(name: 'Sofort') required final Sofort sofort,
@JsonKey(name: 'Ideal') required final Ideal ideal,
@JsonKey(name: 'Fpx') required final Fpx fpx,

Check warning on line 583 in packages/stripe_platform_interface/lib/src/models/payment_methods.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

Fpx

"Fpx" is a typo. Did you mean "Fox"?

Check warning on line 583 in packages/stripe_platform_interface/lib/src/models/payment_methods.freezed.dart

View workflow job for this annotation

GitHub Actions / Typo CI

fpx

"fpx" is a typo. Did you mean "fox"?
@JsonKey(name: 'Upi') required final Upi upi,
@JsonKey(name: 'USBankAccount')
required final UsBankAccount usBankAccount,
required final UsBankAccount usBankAccount,
final String? customerId}) = _$_PaymentMethod;

factory _PaymentMethod.fromJson(Map<String, dynamic> json) =
Expand Down
Loading
Loading