mirror of
https://github.com/spring-projects/spring-security.git
synced 2025-02-28 18:39:06 +00:00
Update UsernameNotFoundException message
Closes gh-16497 Signed-off-by: tejas-teju <tejas8196@gmail.com>
This commit is contained in:
parent
5af4b9a2ad
commit
e724ea16a4
@ -164,7 +164,7 @@ public class InMemoryUserDetailsManager implements UserDetailsManager, UserDetai
|
||||
public UserDetails loadUserByUsername(String username) throws UsernameNotFoundException {
|
||||
UserDetails user = this.users.get(username.toLowerCase(Locale.ROOT));
|
||||
if (user == null) {
|
||||
throw new UsernameNotFoundException(username);
|
||||
throw new UsernameNotFoundException("user '" + username + "' not found");
|
||||
}
|
||||
if (user instanceof CredentialsContainer) {
|
||||
return user;
|
||||
|
Loading…
x
Reference in New Issue
Block a user