From 02f14940e6012e2de1a0636beda5f1421f524989 Mon Sep 17 00:00:00 2001 From: Dominik Mengelt Date: Wed, 1 Jul 2015 17:56:04 +0200 Subject: [PATCH] =?UTF-8?q?Support=20new=20MasterCard=20BIN=20ranges=20(22?= =?UTF-8?q?2100=E2=80=93272099)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- example/index.html | 1 + lib/jquery.payment.js | 2 +- src/jquery.payment.coffee | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/example/index.html b/example/index.html index 8995567..26a19cf 100644 --- a/example/index.html +++ b/example/index.html @@ -1,6 +1,7 @@ + diff --git a/lib/jquery.payment.js b/lib/jquery.payment.js index b773ce0..220a70a 100644 --- a/lib/jquery.payment.js +++ b/lib/jquery.payment.js @@ -54,7 +54,7 @@ luhn: true }, { type: 'mastercard', - pattern: /^5[0-5]/, + pattern: /^(5[0-5]|2[2-7])/, format: defaultFormat, length: [16], cvcLength: [3], diff --git a/src/jquery.payment.coffee b/src/jquery.payment.coffee index b75bae9..e1c132c 100644 --- a/src/jquery.payment.coffee +++ b/src/jquery.payment.coffee @@ -53,7 +53,7 @@ $.payment.cards = cards = [ } { type: 'mastercard' - pattern: /^5[0-5]/ + pattern: /^(5[0-5]|2[2-7])/ format: defaultFormat length: [16] cvcLength: [3]