Open whitecat opened 6 years ago
I am also having this issue. It was previously working.
I'm getting the same issue. Version 1.5.3
I made sure to to make each validation function a knock on and instead used "Await", so I could log any errors between each method. What happens is that it successfully goes through the card number and expiry validation methods, but fails at the CVC validation method.
The highlighted code in Xcode is STPCardValidationState state = [STPCardValidator validationStateForCVC:[command.arguments objectAtIndex:0] cardBrand:STPCardBrandUnknown];
The error being logged is [NSNull rangeOfCharacterFromSet:]: unrecognized selector sent to instance 0x1dd96d9d0
When you check out the Stripe docs I can see that their method for validating the CVC actually takes in both CVC number "cvc" and the card brand "brand". Apparently the brand has another method for finding it, called brandForNumber.
Problematically, this error is occurring regardless of the validity of card details entered. My theory is the the issue is something to do with the card brand not being passed as a parameter correctly. Perhaps exposing the brandForNumber method and making the user pass in the brand as an argument may help to stop this issue?
The following three methods are crashing out when run on iOS. I do not get an error. Calling these functions cause iOS to crash. validateCardNumber validateCVC validateExpiryDate
Here is my ionic info:
I call the methods like this: