// GetContributorsURL returns the ContributorsURL field if it's non-nil, zero value otherwise.
19797
func (r *Repository) GetContributorsURL() string {
	if r == nil || r.ContributorsURL == nil {
		return ""
	}
	return *r.ContributorsURL
}
992299
func (c *Contributor) GetURL() string {
	if c == nil || c.URL == nil {
		return ""
	}
	return *c.URL
}
102872
func (d *DiscussionComment) GetDiscussionURL() string {
	if d == nil || d.DiscussionURL == nil {
		return ""
	}
	return *d.DiscussionURL
}
507748
func (p *Project) GetOwnerURL() string {
	if p == nil || p.OwnerURL == nil {
		return ""
	}
	return *p.OwnerURL
}
722742
func (c *Contributor) GetHTMLURL() string {
	if c == nil || c.HTMLURL == nil {
		return ""
	}
	return *c.HTMLURL
}
1285983
func (r *RepositoryContent) GetURL() string {
	if r == nil || r.URL == nil {
		return ""
	}
	return *r.URL
}
95570
func (p *PullRequestComment) GetHTMLURL() string {
	if p == nil || p.HTMLURL == nil {
		return ""
	}
	return *p.HTMLURL
}
132663
func (r *RepositoryContent) GetHTMLURL() string {
	if r == nil || r.HTMLURL == nil {
		return ""
	}
	return *r.HTMLURL
}
265054
func (f *Feeds) GetCurrentUserURL() string {
	if f == nil || f.CurrentUserURL == nil {
		return ""
	}
	return *f.CurrentUserURL
}
487964
func (r *Repository) GetHTMLURL() string {
	if r == nil || r.HTMLURL == nil {
		return ""
	}
	return *r.HTMLURL
}
1052168
func (r *Repository) GetContentsURL() string {
	if r == nil || r.ContentsURL == nil {
		return ""
	}
	return *r.ContentsURL
}
895562
func (c *Client) GetMetadataURL(id, edition, version string) string {
	return fmt.Sprintf("%s/datasets/%s/editions/%s/versions/%s/metadata", c.url, id, edition, version)
}
697593
func (c *Contributor) GetFollowingURL() string {
	if c == nil || c.FollowingURL == nil {
		return ""
	}
	return *c.FollowingURL
}
1210205
func (c *CommitResult) GetCommentsURL() string {
	if c == nil || c.CommentsURL == nil {
		return ""
	}
	return *c.CommentsURL
}
1133132
func getGetterUrl(taskEnv EnvReplacer, artifact *structs.TaskArtifact) (string, error) {
	source := taskEnv.ReplaceEnv(artifact.GetterSource)

	// Handle an invalid URL when given a go-getter url such as
	// git@github.com:hashicorp/nomad.git
	gitSSH := false
	if strings.HasPrefix(source, gitSSHPrefix) {
		gitSSH = true
		source = source[len(gitSSHPrefix):]
	}

	u, err := url.Parse(source)
	if err != nil {
		return "", fmt.Errorf("failed to parse source URL %q: %v", artifact.GetterSource, err)
	}

	// Build the url
	q := u.Query()
	for k, v := range artifact.GetterOptions {
		q.Add(k, taskEnv.ReplaceEnv(v))
	}
	u.RawQuery = q.Encode()

	// Add the prefix back
	url := u.String()
	if gitSSH {
		url = fmt.Sprintf("%s%s", gitSSHPrefix, url)
	}

	return url, nil
}
645179
func (p *PullRequest) GetReviewCommentURL() string {
	if p == nil || p.ReviewCommentURL == nil {
		return ""
	}
	return *p.ReviewCommentURL
}
59075
func (t *Team) GetRepositoriesURL() string {
	if t == nil || t.RepositoriesURL == nil {
		return ""
	}
	return *t.RepositoriesURL
}