code: func getNameAddr(keysDir, name, addr string) (string, error) {
  	if name == "" && addr == "" {
  		return "", fmt.Errorf("at least one of name or addr must be provided")
  	}
  
  	// name takes precedent if both are given
  	var err error
  	if name != "" {
  		addr, err = coreNameGet(keysDir, name)
  		if err != nil {
  			return "", err
  		}
  	}
  	return strings.ToUpper(addr), nil
  }
docs: // return addr from name or addr