From eb54d899fbf59a61a948e671de95c99ad03e1000 Mon Sep 17 00:00:00 2001 From: Sean Yesmunt Date: Tue, 24 Mar 2020 17:19:39 -0400 Subject: [PATCH] only fetch channel_list when sync returns new data --- ui/redux/actions/app.js | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/ui/redux/actions/app.js b/ui/redux/actions/app.js index f65345bb2..ff6dc48d7 100644 --- a/ui/redux/actions/app.js +++ b/ui/redux/actions/app.js @@ -554,10 +554,15 @@ export function doGetAndPopulatePreferences() { export function doSyncWithPreferences() { return dispatch => { - function handleSyncComplete() { - // we just got sync data, better update our channels - dispatch(doFetchChannelListMine()); - dispatch(doGetAndPopulatePreferences()); + function handleSyncComplete(error, hasNewData) { + if (!error) { + dispatch(doGetAndPopulatePreferences()); + + if (hasNewData) { + // we just got sync data, better update our channels + dispatch(doFetchChannelListMine()); + } + } } return getSavedPassword().then(password => {