checkLeaks static method

Future<LeakSummary> checkLeaks()

Checks for leaks and outputs LeakSummary as configured.

Implementation

static Future<LeakSummary> checkLeaks() async {
  Future<LeakSummary>? result;

  assert(() {
    result = _leakTracker?.leakReporter.checkLeaks();
    return true;
  }());

  return await (result ?? Future.value(LeakSummary({})));
}