initLoggers function

void initLoggers(
  1. Level level,
  2. Set<Logger> loggers
)

Implementation

void initLoggers(Level level, Set<Logger> loggers) {
  hierarchicalLoggingEnabled = true;

  for (final logger in loggers) {
    if (!_activeLoggers.contains(logger)) {
      // ignore: avoid_print
      print("Initializing logger: ${logger.name}");

      logger
        ..level = level
        ..onRecord.listen(printLog);

      _activeLoggers.add(logger);
    }
  }
}