containsDate static method

bool containsDate(
  1. List<DateTime> dates,
  2. DateTime targetDate
)

Implementation

static bool containsDate(List<DateTime> dates, DateTime targetDate) {
  for (DateTime date in dates) {
    if (isSameDay(date, targetDate)) {
      return true;
    }
  }
  return false;
}