You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
to replicate: use card "5473677027371724" (modded number so remove isValid check)
it will loop through the object and the number above will satisfy both mastercard and maestro but the result will be at random, dependent on browser.
your loop takes cards from the CARDS property BUT as that is an object, there are no guarantees on the order in which they arrive (as per ES this is correct).
it's usually in order of entry but not always - IE8 and Chrome can often loop through a different order.
To fix this, I have reverted this.CARDS to an array and then use this.CARDS.some to only get a singular match,
to replicate: use card "5473677027371724" (modded number so remove isValid check)
it will loop through the object and the number above will satisfy both mastercard and maestro but the result will be at random, dependent on browser.
your loop takes cards from the CARDS property BUT as that is an object, there are no guarantees on the order in which they arrive (as per ES this is correct).
it's usually in order of entry but not always - IE8 and Chrome can often loop through a different order.
To fix this, I have reverted
this.CARDS
to an array and then use this.CARDS.some to only get a singular match,Can't be bothered with a pull request but here's a gist of what I use now: https://gist.github.com/1002106
The text was updated successfully, but these errors were encountered: