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

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

Issue 6873112: [Chrome OS] Re-enable fetching the owner's name via SignedSettings (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: address mattias suggestion Created 9 years, 8 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
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/signed_settings_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/login/signed_settings.cc
diff --git a/chrome/browser/chromeos/login/signed_settings.cc b/chrome/browser/chromeos/login/signed_settings.cc
index a056097d0c7ec8a7c024a6cacee07fb3d47f07c6..60418d416d53dac0d3291397ab1fe4bbfddedce5 100644
--- a/chrome/browser/chromeos/login/signed_settings.cc
+++ b/chrome/browser/chromeos/login/signed_settings.cc
@@ -703,6 +703,12 @@ void RetrievePropertyOp::OnKeyOpComplete(
}
std::string RetrievePropertyOp::LookUpInPolicy(const std::string& prop) {
+ if (prop == kDeviceOwner) {
+ const em::PolicyData& data = service_->cached_policy();
+ if (data.has_username() && !data.has_request_token())
+ return data.username();
+ return "";
+ }
em::ChromeDeviceSettingsProto pol;
pol.ParseFromString(service_->cached_policy().policy_value());
if (prop == kAccountsPrefAllowNewUser) {
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/signed_settings_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698