Skip to content

Instantly share code, notes, and snippets.

@SmileyChris
Created December 14, 2010 01:07
Show Gist options
  • Save SmileyChris/739868 to your computer and use it in GitHub Desktop.
Save SmileyChris/739868 to your computer and use it in GitHub Desktop.
class SubscriptionForm(forms.ModelForm):
""" Base form to be extended by providers which require authentication. """
def save(self, *args, **kwargs):
self.instance.credentials = self.serialize()
return super(SubscriptionForm, self).save(*args, **kwargs)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment