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

Unified Diff: chrome/browser/chromeos/login/easy_unlock/easy_unlock_key_manager.cc

Issue 1412813003: This CL replaces user_manager::UserID with AccountId. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@468875--Chrome-OS-handles-deletion-of-Gmail-account-poorly--Create-AccountID-structure-part2--user_names
Patch Set: Update after review. Created 5 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/easy_unlock/easy_unlock_key_manager.cc
diff --git a/chrome/browser/chromeos/login/easy_unlock/easy_unlock_key_manager.cc b/chrome/browser/chromeos/login/easy_unlock/easy_unlock_key_manager.cc
index c1ba482f8700a591071a68b460737137f662102f..752ed8847c523266a985632626947a1a4d9b7e11 100644
--- a/chrome/browser/chromeos/login/easy_unlock/easy_unlock_key_manager.cc
+++ b/chrome/browser/chromeos/login/easy_unlock/easy_unlock_key_manager.cc
@@ -11,6 +11,7 @@
#include "base/values.h"
#include "chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager.h"
#include "chrome/browser/chromeos/login/easy_unlock/easy_unlock_tpm_key_manager_factory.h"
+#include "components/signin/core/account_id/account_id.h"
namespace chromeos {
@@ -52,7 +53,7 @@ void EasyUnlockKeyManager::RefreshKeys(const UserContext& user_context,
EasyUnlockTpmKeyManager* tpm_key_manager =
EasyUnlockTpmKeyManagerFactory::GetInstance()->GetForUser(
- user_context.GetUserID());
+ user_context.GetAccountId().GetUserEmail());
if (!tpm_key_manager) {
LOG(ERROR) << "No TPM key manager.";
callback.Run(false);
@@ -81,9 +82,9 @@ void EasyUnlockKeyManager::RefreshKeysWithTpmKeyPresent(
const RefreshKeysCallback& callback) {
EasyUnlockTpmKeyManager* tpm_key_manager =
EasyUnlockTpmKeyManagerFactory::GetInstance()->GetForUser(
- user_context.GetUserID());
- std::string tpm_public_key =
- tpm_key_manager->GetPublicTpmKey(user_context.GetUserID());
+ user_context.GetAccountId().GetUserEmail());
+ std::string tpm_public_key = tpm_key_manager->GetPublicTpmKey(
achuithb 2015/10/28 23:11:44 const
Alexander Alekseev 2015/10/29 02:00:40 Done.
+ user_context.GetAccountId().GetUserEmail());
EasyUnlockDeviceKeyDataList devices;
if (!RemoteDeviceListToDeviceDataList(*remote_devices, &devices))

Powered by Google App Engine
This is Rietveld 408576698