fixed problems with date format