laterOf function

Date? laterOf(
  1. Date a,
  2. Date? b
)

Gets the later of the two given dates.

Requires both dates to be non-null.

Implementation

Date? laterOf(Date a, Date? b) => a.isAfter(b) ? a : b;