isEqualTo method
Check if this nullable DateTime equals another nullable DateTime Returns true only if both are null or both have same moment
Implementation
bool isEqualTo(DateTime? other) {
if (other == null && this == null) return true;
if (other == null || this == null) return false;
return this!.isAtSameMomentAs(other);
}