From e1b80c33173a3f3d84a5bc9f6dc657065a48bd7a Mon Sep 17 00:00:00 2001 From: Chi Vinh Le Date: Tue, 16 May 2017 17:50:17 +0700 Subject: [PATCH] Only refetch for login --- client/coral-settings/containers/ProfileContainer.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/coral-settings/containers/ProfileContainer.js b/client/coral-settings/containers/ProfileContainer.js index 84c2c1642..a9355d918 100644 --- a/client/coral-settings/containers/ProfileContainer.js +++ b/client/coral-settings/containers/ProfileContainer.js @@ -26,9 +26,9 @@ class ProfileContainer extends Component { } componentWillReceiveProps(nextProps) { - if (this.props.auth.loggedIn !== nextProps.auth.loggedIn) { + if (!this.props.auth.loggedIn && nextProps.auth.loggedIn) { - // Refetch after login/logout. + // Refetch after login. this.props.data.refetch(); } }