jondavidjohn / payform

:credit_card: A library for building credit card forms, validating inputs, and formatting numbers.
https://jondavidjohn.github.io/payform/
Other
427 stars 81 forks source link

Maestro card entry stops short of last 2 digits #25

Closed markolofsen closed 6 years ago

markolofsen commented 7 years ago

Can't input 6390 XXXX XXXX XXXX XX

jondavidjohn commented 7 years ago

😬 Plz don't publish actual card numbers

Verified the problem is that the input stops before the last 2 numbers.

Thanks for the report 👍

Stephs15 commented 7 years ago

Hey @jondavidjohn First of all, great job... So I was wondering on the restrictCardNumber function you have the following code

if card and value.length > card.length[card.length.length - 1] e.preventDefault() else if value.length > 16 e.preventDefault()

Won't this restrict any card to a top of 16 digits?

voronianski commented 6 years ago

@markolofsen @Stephs15 any known workaround on this?

voronianski commented 6 years ago

this patch should fix the problem ☝️

jondavidjohn commented 6 years ago

Hi @markolofsen, is this no longer an issue with the published release?

markolofsen commented 6 years ago

@jondavidjohn don't know)