Fix sync count bug.