Index: components/user_manager/user_manager_base.cc |
diff --git a/components/user_manager/user_manager_base.cc b/components/user_manager/user_manager_base.cc |
index 444bb3487009ab59264ffc68418a94396306dd2e..8cd5d50b9c150a4d705c8c92d5ce25fb12fdb9e8 100644 |
--- a/components/user_manager/user_manager_base.cc |
+++ b/components/user_manager/user_manager_base.cc |
@@ -16,6 +16,7 @@ |
#include "base/location.h" |
#include "base/logging.h" |
#include "base/macros.h" |
+#include "base/memory/ptr_util.h" |
#include "base/metrics/histogram.h" |
#include "base/strings/string_util.h" |
#include "base/strings/stringprintf.h" |
@@ -851,7 +852,8 @@ void UserManagerBase::GuestUserLoggedIn() { |
void UserManagerBase::AddUserRecord(User* user) { |
// Add the user to the front of the user list. |
ListPrefUpdate prefs_users_update(GetLocalState(), kRegularUsers); |
- prefs_users_update->Insert(0, new base::StringValue(user->email())); |
+ prefs_users_update->Insert( |
+ 0, base::MakeUnique<base::StringValue>(user->email())); |
users_.insert(users_.begin(), user); |
} |