correcting conditional error on photos date check