Added sync when coming back from background.