Added sync in login.