code: @Override
    protected void checkDaoConfig() {
      super.checkDaoConfig();
      notNull(this.mapperInterface, "Property 'mapperInterface' is required");
  
      Configuration configuration = getSqlSession().getConfiguration();
      if (this.addToConfig && !configuration.hasMapper(this.mapperInterface)) {
        try {
          configuration.addMapper(this.mapperInterface);
        } catch (Throwable t) {
          logger.error("Error while adding the mapper '" + this.mapperInterface + "' to configuration.", t);
          throw new IllegalArgumentException(t);
        } finally {
          ErrorContext.instance().reset();
        }
      }
    }
docs: {@inheritDoc}