fixed datetime issue