bendrucker/angular-credit-cards

Discover Card # not validating

snowdave86 opened this issue · 1 comments

6011111111111117 Discover Card # does not validate nor does it work in eager Pattern.

Current:

pattern: /^6(011(0[0-9]|[2-4]\d|74|7[7-9]|8[6-9]|9[0-9])|4[4-9]\d{3}|5\d{4})\d{10}$/,
eagerPattern: /^6(011(0[0-9]|[2-4]|74|7[7-9]|8[6-9]|9[0-9])|4[4-9]|5)/

So I know that's one of Stripe's test card patterns. It's actually not in any documented BIN ranges I've ever seen, including Discover's official range docs. creditcards-types backs this library and I try to keep that library as in line with card issuer specs as possible. I'd recommend sticking to the second Stripe test card number which is fully valid.