fixed date sort issue