MCPcopy Create free account
hub / github.com/cli/cli / deleteLabel

Function deleteLabel

pkg/cmd/label/delete.go:96–104  ·  view source on GitHub ↗
(client *http.Client, repo ghrepo.Interface, name string)

Source from the content-addressed store, hash-verified

94}
95
96func deleteLabel(client *http.Client, repo ghrepo.Interface, name string) error {
97 apiClient := api.NewClientFromHTTP(client)
98 path, err := safeurl.JoinPath("repos", repo.RepoOwner(), repo.RepoName(), "labels", name)
99 if err != nil {
100 return err
101 }
102
103 return apiClient.REST(repo.RepoHost(), "DELETE", path.String(), nil, nil)
104}

Callers 1

deleteRunFunction · 0.85

Calls 7

NewClientFromHTTPFunction · 0.92
JoinPathFunction · 0.92
RepoOwnerMethod · 0.65
RepoNameMethod · 0.65
RESTMethod · 0.65
RepoHostMethod · 0.65
StringMethod · 0.65

Tested by

no test coverage detected