docs: def _credit_card_type(self, card_type=None):
          """ Returns a random credit card type instance. """
          if card_type is None:
              card_type = self.random_element(self.credit_card_types.keys())
          elif isinstance(card_type, CreditCard):
              return card_type
          return self.credit_card_types[card_type]