isExpired property Null safety

bool isExpired

Whether or not this code has expired yet, according to its expirationDate.

Implementation

bool get isExpired {
  return expirationDate!.difference(DateTime.now().toUtc()).inSeconds <= 0;
}