Fix date saving issue.