From cc1f6e46dd146ebf0e6b6a8de5efa4df51ffe625 Mon Sep 17 00:00:00 2001 From: Evan Morikawa Date: Thu, 5 May 2016 15:24:51 -0700 Subject: [PATCH] feat(babel6): Don't use _.clone on Model objects --- .../preferences/lib/tabs/preferences-account-details.jsx | 4 ++-- src/flux/models/account.es6 | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/internal_packages/preferences/lib/tabs/preferences-account-details.jsx b/internal_packages/preferences/lib/tabs/preferences-account-details.jsx index 33b42149d..9eab25e9e 100644 --- a/internal_packages/preferences/lib/tabs/preferences-account-details.jsx +++ b/internal_packages/preferences/lib/tabs/preferences-account-details.jsx @@ -12,11 +12,11 @@ class PreferencesAccountDetails extends Component { constructor(props) { super(props); - this.state = {account: _.clone(props.account)}; + this.state = {account: props.account.clone()}; } componentWillReceiveProps(nextProps) { - this.setState({account: _.clone(nextProps.account)}); + this.setState({account: nextProps.account.clone()}); } componentWillUnmount() { diff --git a/src/flux/models/account.es6 b/src/flux/models/account.es6 index c4951475f..5a2f66fc3 100644 --- a/src/flux/models/account.es6 +++ b/src/flux/models/account.es6 @@ -77,7 +77,7 @@ export default class Account extends ModelWithMetadata { modelKey: 'syncState', jsonKey: 'sync_state', }), - }) + }); constructor(args) { super(args)