Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
fix typo
  • Loading branch information
Maisy authored Feb 1, 2020
commit c86982bb567f62a1db527a6ebeb6d452afa4de5a
4 changes: 2 additions & 2 deletions custom-error/README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ public OAuth2UserService<OAuth2UserRequest, OAuth2User> oauth2UserService(WebCli
DefaultOAuth2UserService delegate = new DefaultOAuth2UserService();
return request -> {
OAuth2User user = delegate.loadUser(request);
if (!"github".equals(request.getClientRegistration.getRegistrationId())) {
if (!"github".equals(request.getClientRegistration().getRegistrationId())) {
return user;
}

Expand Down Expand Up @@ -148,4 +148,4 @@ public WebClient rest(ClientRegistrationRepository clients, OAuth2AuthorizedClie
----

TIP: Obviously the code above can be generalized to other authentication rules, some applicable to GitHub and some to other OAuth 2.0 providers.
All you need is the `WebClient` and some knowledge of the provider's API.
All you need is the `WebClient` and some knowledge of the provider's API.