code: func (m *Meta) Config(path string) (*config.Config, error) {
  	// If no explicit path was given then it is okay for there to be
  	// no backend configuration found.
  	emptyOk := path == ""
  
  	// If we had no path set, it is an error. We can't initialize unset
  	if path == "" {
  		path = "."
  	}
  
  	// Expand the path
  	if !filepath.IsAbs(path) {
  		var err error
  		path, err = filepath.Abs(path)
  		if err != nil {
  			return nil, fmt.Errorf(
  				"Error expanding path to backend config %q: %s", path, err)
  		}
  	}
  
  	log.Printf("[DEBUG] command: loading backend config file: %s", path)
  
  	// We first need to determine if we're loading a file or a directory.
  	fi, err := os.Stat(path)
  	if err != nil {
  		if os.IsNotExist(err) && emptyOk {
  			log.Printf(
  				"[INFO] command: backend config not found, returning nil: %s",
  				path)
  			return nil, nil
  		}
  
  		return nil, err
  	}
  
  	var f func(string) (*config.Config, error) = config.LoadFile
  	if fi.IsDir() {
  		f = config.LoadDir
  	}
  
  	// Load the configuration
  	c, err := f(path)
  	if err != nil {
  		// Check for the error where we have no config files and return nil
  		// as the configuration type.
  		if errwrap.ContainsType(err, new(config.ErrNoConfigsFound)) {
  			log.Printf(
  				"[INFO] command: backend config not found, returning nil: %s",
  				path)
  			return nil, nil
  		}
  
  		return nil, err
  	}
  
  	return c, nil
  }
docs: // Config loads the root config for the path specified, using the legacy
  // configuration loader.
  //
  // Path may be a directory or file. The absence of configuration is not an
  // error and returns a nil Config.