From d59a5da3213dcbb07c2c544191242bb06df2e69f Mon Sep 17 00:00:00 2001 From: Ben Alex Date: Sun, 28 Mar 2004 12:16:44 +0000 Subject: [PATCH] Changed to not detect null returns, as the UserMap will now throw the UsernameNotFoundException. --- .../acegisecurity/userdetails/memory/InMemoryDaoImpl.java | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/core/src/main/java/org/acegisecurity/userdetails/memory/InMemoryDaoImpl.java b/core/src/main/java/org/acegisecurity/userdetails/memory/InMemoryDaoImpl.java index 29796a5a4d..ffb5d01138 100644 --- a/core/src/main/java/org/acegisecurity/userdetails/memory/InMemoryDaoImpl.java +++ b/core/src/main/java/org/acegisecurity/userdetails/memory/InMemoryDaoImpl.java @@ -54,12 +54,6 @@ public class InMemoryDaoImpl implements AuthenticationDao, InitializingBean { public User loadUserByUsername(String username) throws UsernameNotFoundException, DataAccessException { - User result = userMap.getUser(username); - - if (result == null) { - throw new UsernameNotFoundException("User could not be found"); - } - - return result; + return userMap.getUser(username); } }