Rewrite of syncing