fixing date ranges