removeHandler method

void removeHandler(
  1. LogHandler handler, {
  2. String channel = 'app',
})

Removes a log handler from a specific channel.

Implementation

void removeHandler(LogHandler handler, {String channel = 'app'}) {
  final handlers = _channels[channel];
  if (handlers != null) {
    handlers.remove(handler);
    if (handlers.isEmpty) {
      _channels.remove(channel);
    }
  }
}