Commit 5d94e5e74a19a876f955afb779d0ffb98a193342
1 parent
a4d651eb
Minor improvement for oauth2 success handler
Showing
1 changed file
with
1 additions
and
0 deletions
... | ... | @@ -91,6 +91,7 @@ public class Oauth2AuthenticationSuccessHandler extends SimpleUrlAuthenticationS |
91 | 91 | clearAuthenticationAttributes(request, response); |
92 | 92 | getRedirectStrategy().sendRedirect(request, response, baseUrl + "/?accessToken=" + accessToken.getToken() + "&refreshToken=" + refreshToken.getToken()); |
93 | 93 | } catch (Exception e) { |
94 | + clearAuthenticationAttributes(request, response); | |
94 | 95 | getRedirectStrategy().sendRedirect(request, response, baseUrl + "/login?loginError=" + |
95 | 96 | URLEncoder.encode(e.getMessage(), StandardCharsets.UTF_8.toString())); |
96 | 97 | } | ... | ... |