Improved date handling in DateUtil