braintree / credit-card-type

A library for determining credit card type

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Master Cards starts with 2-series are shown as invalid

Sanketh1220 opened this issue · comments

General information

  • Library version: 9.1.0
  • Chrome Version 96.0.4664.45 (64-bit) on Windows 11

Issue description

I have used it for card validation in one my project when am using with master card which starts with 2-series even when I enter a valid card it shows invalid.

Thanks for bringing this up, @Sanketh1220. Support for Mastercard 2-series should have been added in version 6.1.1.

Here is the pattern that we use to validate Mastercards. If you can provide us with official documentation from Mastercard that we need to add some ranges to our pattern then we can get this fixed. Feel free to also open up a PR citing any official Mastercard documentation. We'll leave this issue open in the meantime.

Closing this since we haven't heard back from OP.