fixed date parsing bug