Commits

Carmel Avnon committed 205728f

Use kwargs instead of args in CreditCardForm.init

Comments (0)

Files changed (1)

satchmo/apps/payment/forms.py

     year_expires = forms.ChoiceField()
     ccv = forms.CharField(max_length=4, label='Sec code', widget=forms.TextInput(attrs={'autocomplete':'off'}))
 
-    def __init__(self, request, paymentmodule, *args, **kwargs):
+    def __init__(self, *args, **kwargs):
+        request = kwargs.get('request')
+        paymentmodule = kwargs.get('paymentmodule')
         creditchoices = paymentmodule.CREDITCHOICES.choice_values
-        super(CreditCardForm, self).__init__(request, paymentmodule, *args, **kwargs)
+        super(CreditCardForm, self).__init__(*args, **kwargs)
 
         self.cc = None