roundToDayStart static method

DateTime roundToDayStart(
  1. DateTime date
)

Rounds the given DateTime to the start of the day (00:00:00).

Implementation

static DateTime roundToDayStart(DateTime date) {
  return DateTime(date.year, date.month, date.day);
}