Fix date comparison.