Index: chrome/browser/chromeos/login/login_utils.cc |
diff --git a/chrome/browser/chromeos/login/login_utils.cc b/chrome/browser/chromeos/login/login_utils.cc |
index 93786b7f952cbf7bdc06e10c517e994bbb077892..4323f8d24905ac50166abf6b498c95f51da0527e 100644 |
--- a/chrome/browser/chromeos/login/login_utils.cc |
+++ b/chrome/browser/chromeos/login/login_utils.cc |
@@ -139,18 +139,7 @@ void LoginUtilsImpl::CompleteLogin(const std::string& username, |
if (CrosLibrary::Get()->EnsureLoaded()) |
CrosLibrary::Get()->GetLoginLibrary()->StartSession(username, ""); |
- const std::vector<UserManager::User>& users = UserManager::Get()->GetUsers(); |
- |
- bool first_login = true; |
- for (std::vector<UserManager::User>::const_iterator it = users.begin(); |
- it < users.end(); ++it) { |
- std::string user_email = it->email(); |
- if (username == user_email) { |
- first_login = false; |
- break; |
- } |
- } |
- |
+ bool first_login = !UserManager::Get()->IsKnownUser(username); |
UserManager::Get()->UserLoggedIn(username); |
// Now launch the initial browser window. |