hellocoop / wordpress

A login and registration WordPress plugin for the Hellō service.
4 stars 2 forks source link

gracefully handled cancelled authorization #102

Closed mscurtescu closed 1 year ago

mscurtescu commented 1 year ago

Describe the bug Cancelled login not handled gracefully, but rather as generic unknown error.

To Reproduce Steps to reproduce the behavior:

  1. Start the sign-in flow by clicking the "Continue with Hellō" button.
  2. On the Hellō consent page click "Cancel" (bottom left).
  3. You are redirected back to /wp-login.php
  4. Notice the "ERROR (unknown-error): An unknown error occurred." error block and also the login-error=unknown-error&message=An+unknown+error+occurred. query parameters.

Screenshots

image

image

Expected behavior

The /wp-login.php page should display a meaningful error message, like "Login cancelled".

mscurtescu commented 1 year ago

https://github.com/hellocoop/wordpress/commit/e78967c933487d002e09fe1d022aa941c435c1bf

image