Skip to content

Instantly share code, notes, and snippets.

@groovecoder
Created July 16, 2014 16:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save groovecoder/2efb2e3206333b5e69a4 to your computer and use it in GitHub Desktop.
Save groovecoder/2efb2e3206333b5e69a4 to your computer and use it in GitHub Desktop.
def form_valid(self, form):
"""
We send our welcome email via celery during complete_signup.
So, we need to manually commit the user to the db for it.
"""
with transaction.commit_on_success():
form.save(self.request)
return helpers.complete_social_signup(self.request,
self.sociallogin)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment