Fix a bug where the credential is (weirdly only sometimes) null after creating a new user account.  Django seems to reset the value of request.session after authentication, but only sometimes.  So get the credential out of the session before it gets reset.