Small refactoring of the loadingBar hiding code
Fix loadingBar hiding when disableAutoFetch is enabled (issue 3590)
Merge pull request #5203 from Snuffleupagus/disableAutoFetch-loadingBar

Fix loadingBar hiding when disableAutoFetch is enabled (issue 3590)