bugfix, optimize isValidDate realization greatly