Closed boris-savic closed 11 years ago
I think that this should be fixed in Facebook backend since it's the only code that will use that so far.
I haven't tested Google oAuth or Twitter indeed, but anyway I find it inconvenient that in case of AuthException thing just dies instead redirects to LOGIN_ERROR_URL.
@boris-savic, for that purpose there's a middleware to properly handle the errors, you can extend it and override the behavior if needed.
Wasn't aware of that. Thanks.
@boris-savic, no problem, here's a link to docs http://django-social-auth.readthedocs.org/en/latest/configuration.html#exceptions-middleware. I'll close this PR.
Facebook redirects users to /complete/facebook when they click on shared via APP_NAME in posts that have beed shared via FB app. This is annoying since the purpose of that url is for facebook callbacks to complete user authentication. Since we can't specify two different URLs in FB App settings it makes sense to fix the bug that causes the page to crash if complete url is called with no completion parameters.
This commit fixes the HTTP 500 error that was generated if no parameters were provided (as they are if users login via /login/facebook). It now redirects user to error page if configured.