fixing date issues