aboutsummaryrefslogtreecommitdiff
path: root/src/privet/mock_delegates.h
diff options
context:
space:
mode:
authorAlex Vakulenko <avakulenko@google.com>2016-03-28 15:41:49 -0700
committerAlex Vakulenko <avakulenko@google.com>2016-03-29 15:05:55 +0000
commit38a2aef3d483ef9bd73989a0a25a636a7d03cad9 (patch)
treee334ff22c7d5bb72653a3ee97918658b5f030361 /src/privet/mock_delegates.h
parentbf79a9eb710d8c9df6ab3e5e305ff6c881a19ab2 (diff)
downloadlibweave-38a2aef3d483ef9bd73989a0a25a636a7d03cad9.tar.gz
libweave: Remove release() calls on scoped_ptr
Now that scoped_ptr is just a type alias to std::unique_ptr, there is no need to do release()/aquire semantics to convert between scoped_ptr and unique_ptr. Also, replaced base::Value::DeepCopy with the safer smart-pointer-enabled base::Value::CreateDeepCopy. Change-Id: I6b7ed78b3fae6d42a68b7d73ae4d9d5eebf48922 Reviewed-on: https://weave-review.googlesource.com/3067 Reviewed-by: Robert Ginda <rginda@google.com>
Diffstat (limited to 'src/privet/mock_delegates.h')
-rw-r--r--src/privet/mock_delegates.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/privet/mock_delegates.h b/src/privet/mock_delegates.h
index 3742494..5338e1b 100644
--- a/src/privet/mock_delegates.h
+++ b/src/privet/mock_delegates.h
@@ -263,8 +263,7 @@ class MockCloudDelegate : public CloudDelegate {
private:
std::unique_ptr<base::DictionaryValue> GetComponentsForUser(
const UserInfo& user_info) const override {
- return std::unique_ptr<base::DictionaryValue>{
- MockGetComponentsForUser(user_info).DeepCopy()};
+ return MockGetComponentsForUser(user_info).CreateDeepCopy();
}
};