Redirect to referer on successful auth.
Convert app to work with new code.
Correct response code for wrong user.