aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhscham <hscham@chromium.org>2020-07-01 03:20:08 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2020-07-01 03:20:08 +0000
commit9620558042fa00cd5b94b10ffe440450030820b2 (patch)
tree942df9a9eeb4fc7f77ce9cc8e8ff81c895144977
parentbb9b65f388a5126d12983a4a5978a6d8cd499fb6 (diff)
parent7a76d80e7f7dd8b9b2784f9adb3bae7e834e4828 (diff)
downloadlibbrillo-9620558042fa00cd5b94b10ffe440450030820b2.tar.gz
libbrillo: remove base::ValueReferenceAdapter am: 690d8d51a6 am: 7a76d80e7f
Original change: https://android-review.googlesource.com/c/platform/external/libbrillo/+/1353563 Change-Id: I55c6fff44f42b1c0c3817293ac47e3d2305ac16c
-rw-r--r--brillo/value_conversion.h2
-rw-r--r--policy/device_policy_impl.cc4
2 files changed, 3 insertions, 3 deletions
diff --git a/brillo/value_conversion.h b/brillo/value_conversion.h
index 6cf7323..b0d61a1 100644
--- a/brillo/value_conversion.h
+++ b/brillo/value_conversion.h
@@ -74,7 +74,7 @@ bool FromValue(const base::Value& in_value, std::vector<T, Alloc>* out_value) {
return false;
out_value->clear();
out_value->reserve(list->GetSize());
- for (const base::Value& item : base::ValueReferenceAdapter(*list)) {
+ for (const base::Value& item : *list) {
T value{};
if (!FromValue(item, &value))
return false;
diff --git a/policy/device_policy_impl.cc b/policy/device_policy_impl.cc
index 3f96d12..72d30b1 100644
--- a/policy/device_policy_impl.cc
+++ b/policy/device_policy_impl.cc
@@ -560,7 +560,7 @@ bool DevicePolicyImpl::GetDeviceUpdateStagingSchedule(
if (!list_val)
return false;
- for (const auto& pair_value : base::ValueReferenceAdapter(*list_val)) {
+ for (const auto& pair_value : *list_val) {
const base::DictionaryValue* day_percentage_pair;
if (!pair_value.GetAsDictionary(&day_percentage_pair))
return false;
@@ -654,7 +654,7 @@ bool DevicePolicyImpl::GetDisallowedTimeIntervals(
if (!list_val)
return false;
- for (const auto& interval_value : base::ValueReferenceAdapter(*list_val)) {
+ for (const auto& interval_value : *list_val) {
const base::DictionaryValue* interval_dict;
if (!interval_value.GetAsDictionary(&interval_dict)) {
LOG(ERROR) << "Invalid JSON string given. Interval is not a dict.";