braintree / android-card-form

A ready-made card form layout that can be included in your Android app, making it easy to accept credit and debit cards.
MIT License
366 stars 128 forks source link

ExpirationDateDialog allows only 10 years in advance (vs. 20 in DateValidator) #25

Closed hellmund closed 7 years ago

hellmund commented 7 years ago

We have some users who are unable to select their credit card's expiration date through ExpirationDateDialog - in case the expiration date is >10 years in the future. Meanwhile, the corresponding client-side validator technically allows for 20 years (see com.braintreepayments.cardform.utils.DateValidator.MAXIMUM_VALID_YEAR_DIFFERENCE)

Possible fix:

lkorth commented 7 years ago

Thanks for pointing this out @hellmund. I've updated it to use DateValidator.MAXIMUM_VALID_YEAR_DIFFERENCE.

This will go out in the next release.