deregister method Null safety

void deregister(
  1. Metric metric
)

Deregister Metrics to make them not visible to developer tooling.

Implementation

static void deregister(Metric metric) {
  // TODO: When NNBD is complete, delete the following line.
  ArgumentError.checkNotNull(metric, 'metric');
  _metrics.remove(metric.name);
}