AddBlockedBy marks an issue as blocked by another issue.
(client *Client, hostname string, issueID string, blockingIssueID string)
| 588 | |
| 589 | // AddBlockedBy marks an issue as blocked by another issue. |
| 590 | func AddBlockedBy(client *Client, hostname string, issueID string, blockingIssueID string) error { |
| 591 | type AddBlockedByInput struct { |
| 592 | IssueID githubv4.ID `json:"issueId"` |
| 593 | BlockingIssueID githubv4.ID `json:"blockingIssueId"` |
| 594 | } |
| 595 | |
| 596 | var mutation struct { |
| 597 | AddBlockedBy struct { |
| 598 | Issue struct { |
| 599 | ID string |
| 600 | } |
| 601 | } `graphql:"addBlockedBy(input: $input)"` |
| 602 | } |
| 603 | |
| 604 | variables := map[string]any{ |
| 605 | "input": AddBlockedByInput{ |
| 606 | IssueID: githubv4.ID(issueID), |
| 607 | BlockingIssueID: githubv4.ID(blockingIssueID), |
| 608 | }, |
| 609 | } |
| 610 | |
| 611 | return client.Mutate(hostname, "AddBlockedBy", &mutation, variables) |
| 612 | } |
| 613 | |
| 614 | // RemoveBlockedBy removes a "blocked by" relationship between two issues. |
| 615 | func RemoveBlockedBy(client *Client, hostname string, issueID string, blockingIssueID string) error { |
no test coverage detected