getEndTime method

Future<DateTime?> getEndTime()

Returns the timestamp when the cooldown will expire, or null if not active.

Implementation

Future<DateTime?> getEndTime() async {
  final last = await _lastActivated.get();
  return last?.add(duration);
}