updated userinfouserdetailsservice to use username instead of userid -- this should actually be a wrapper class though

pull/105/merge
Justin Richer 2012-07-10 16:44:29 -04:00
parent b0a7ebd9b1
commit 9f16f309bd
1 changed files with 2 additions and 1 deletions

View File

@ -53,7 +53,8 @@ public class UserInfoUserDetailsService implements UserDetailsService {
authorities.add(ROLE_ADMIN); authorities.add(ROLE_ADMIN);
} }
User user = new User(userInfo.getUserId(), password, enabled, accountNonExpired, credentialsNonExpired, accountNonLocked, authorities); // TODO: this should really be our own UserDetails wrapper class, shouldn't it?
User user = new User(userInfo.getPreferredUsername(), password, enabled, accountNonExpired, credentialsNonExpired, accountNonLocked, authorities);
return user; return user;
} else { } else {
return null; return null;