freckle/yesod-auth-oauth2

use onErrorHtml for errors

Closed this issue · 1 comments

Presently, when we encounter exceptions during OAuth2 login, we:

  • Log the full details
  • Set a user-friendly message via setMessage
  • Redirect to loginDest (or just call loginHandler, I can't remember)

This is fine, but using onErrorHtml is more conceptually correct, and respects user-choice in terms of how to handle auth errors. And using onErrorHtml loginDest message will result in the same behavior in a default YesodAuth instance.

Fixed in ab17f21.