patches ensureDateAndTime