fixing some date formating and validations