(repo ghrepo.Interface, branch string)
| 63 | } |
| 64 | |
| 65 | func getReadmePath(repo ghrepo.Interface, branch string) (safeurl.SafeURL, error) { |
| 66 | path, err := safeurl.JoinPath("repos", repo.RepoOwner(), repo.RepoName(), "readme") |
| 67 | if err != nil { |
| 68 | return nil, err |
| 69 | } |
| 70 | if branch != "" { |
| 71 | path.SetQuery("ref", branch) |
| 72 | } |
| 73 | return path, nil |
| 74 | } |
no test coverage detected