isSameDate function
Returns true if the two dates are the same. params DateTime The first date. params DateTime The second date.
Implementation
bool isSameDate(DateTime date1, DateTime date2) {
return date1.year == date2.year &&
date1.month == date2.month &&
date1.day == date2.day;
}