Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(144)

Unified Diff: chrome/browser/chromeos/login/login_performer.cc

Issue 8091002: PART2: Make SignedSettings use proper Value types instead of string all around the place. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed comments and fixed an issue with user whitelist checks. Created 9 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/login/login_performer.cc
diff --git a/chrome/browser/chromeos/login/login_performer.cc b/chrome/browser/chromeos/login/login_performer.cc
index c6e857dd970a84ad17415414b7ce213ab258843f..7dbb91300d3176538c376b945fe3837c52955a43 100644
--- a/chrome/browser/chromeos/login/login_performer.cc
+++ b/chrome/browser/chromeos/login/login_performer.cc
@@ -281,10 +281,7 @@ void LoginPerformer::CompleteLogin(const std::string& username,
StartLoginCompletion();
} else {
// Otherwise, do whitelist check first.
- const base::ListValue *user_list;
- base::StringValue username_value(username);
- if (cros_settings->GetList(kAccountsPrefUsers, &user_list) &&
- user_list->Find(username_value) != user_list->end()) {
+ if (cros_settings->FindEmailInList(kAccountsPrefUsers, username)) {
Mattias Nissler (ping if slow) 2011/10/28 14:44:07 why has this worked before if we didn't check *@do
pastarmovj 2011/11/18 13:18:42 Because there is some code that whitelists existin
StartLoginCompletion();
} else {
if (delegate_)
@@ -326,10 +323,7 @@ void LoginPerformer::Login(const std::string& username,
// Starts authentication if guest login is allowed or online auth pending.
StartAuthentication();
} else {
- const base::ListValue *user_list;
- base::StringValue username_value(username);
- if (cros_settings->GetList(kAccountsPrefUsers, &user_list) &&
- user_list->Find(username_value) != user_list->end()) {
+ if (cros_settings->FindEmailInList(kAccountsPrefUsers, username)) {
StartAuthentication();
} else {
if (delegate_)

Powered by Google App Engine
This is Rietveld 408576698