code: public Level level(Config config, Throwable error) {
      if (error == null) {
        return config.defaultMessageLevel();
      }
      if (error instanceof Error) {
        return config.defaultErrorLevel();
      }
      return config.defaultThrowableLevel();
    }
docs: Get the level of the error or message. The Config passed in contains the defaults
  to use for the cases of an Error, Throwable, or a Message. The default in the Config
  if otherwise left unspecified is: CRITICAL for {@link Error}, ERROR for other
  {@link Throwable}, WARNING for messages. Use the methods on ConfigBuilder to
  change these defaults
  
  @param config the current Config.
  @param error the error.
  @return the level.