initLogger function Null safety

void initLogger(
  1. LogLevel lvl
)

Implementation

void initLogger(LogLevel lvl) {
  final level = convertLogLevel(lvl);
  logger = Logger(
    level: level,
    printer: PrefixPrinter(
      PrettyPrinter(
        methodCount: 0, // number of method calls to be displayed
        errorMethodCount: 8, // number of method calls if stacktrace is provided
        lineLength: 100, // width of the output
        colors: true, // Colorful log messages
        printEmojis: true, // Print an emoji for each log message
        printTime: false, // Should each log print contain a timestamp
      ),
      info: '[Sendbird][I]',
      error: '[Sendbird][E]',
      warning: '[Sendbird][W]',
    ),
  );
}