bool checkSameDay(DateTime? a, DateTime? b) { if (a == null || b == null) { return false; } return a.year == b.year && a.month == b.month && a.day == b.day; }