- π―π΄Jordan Anas_maw
Hello
I think the best option here is to add a hook alter in the getTypes function inside CreditCard class
Commerce Payment provides a CreditCard
class, which defines a number of known card types with basic property validation criteria. In working on the Braintree integration module, it appears they return a broader universe of possible card types, including the following which are not currently defined in Payment:
solo
switch
laser
carte blanche
unknown
To my knowledge, the first two are commonly encountered in the field (they're debit cards, but still "plastic.") The Carte Blanche brand was bought by Diners Club and appears to run on their network, now, however it's unknown if gateways still return the card type as a distinct entry when run as a "Diners Club Carte Blanche" card.
Also not sure what the maintainers' approach is regarding unknown card types. At current, a payment method must specify a valid name from the CreditCard
class to work, so it's likely we'll need to expand the universe and possibly handle edge cases.
Active
2.0
Payment
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
Hello
I think the best option here is to add a hook alter in the getTypes function inside CreditCard class