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
It looks like whenever we get invalid_bank_account_iban error in herestripeErrorMessage is not nil and the function doesn't add the correct value to NSLocalizedDescription. Instead of containing the The IBAN you entered is invalid. string it contains the generic message.
We want to display a relevant message to our users based on the error but NSLocalizedDescription doesn't give us any information
Code to reproduce
Call
let sepaDebitParams = STPPaymentMethodSEPADebitParams()
sepaDebitParams.iban = ibanField.text
let billingDetails = STPPaymentMethodBillingDetails()
billingDetails.name = nameField.text
billingDetails.email = emailField.text
let paymentIntentParams = STPPaymentIntentParams(clientSecret: paymentIntentClientSecret)
paymentIntentParams.paymentMethodParams = STPPaymentMethodParams(sepaDebit: sepaDebitParams,
billingDetails: billingDetails,
metadata: nil)
STPPaymentHandler.shared().confirmPayment(paymentIntentParams, with: self) { (handlerStatus, paymentIntent, error) in
print(error)
}
and the error we get is
Error Domain=com.stripe.lib Code=50 "There was an unexpected error -- try again in a few seconds" UserInfo={com.stripe.lib:ErrorMessageKey=The provided IBAN is invalid., com.stripe.lib:StripeErrorTypeKey=invalid_request_error, NSLocalizedDescription=There was an unexpected error -- try again in a few seconds, com.stripe.lib:StripeErrorCodeKey=invalid_bank_account_iban}
iOS version
all
Installation method
pod
SDK version
23.19.0
The text was updated successfully, but these errors were encountered:
Summary
It looks like whenever we get
invalid_bank_account_iban
error in herestripeErrorMessage
is not nil and the function doesn't add the correct value toNSLocalizedDescription
. Instead of containing theThe IBAN you entered is invalid.
string it contains the generic message.We want to display a relevant message to our users based on the error but
NSLocalizedDescription
doesn't give us any informationCode to reproduce
Call
and the error we get is
iOS version
all
Installation method
pod
SDK version
23.19.0
The text was updated successfully, but these errors were encountered: