moved date updating code