diff --git a/clients/githubrepo/checkruns.go b/clients/githubrepo/checkruns.go index 741429de27a..3629e9f3945 100644 --- a/clients/githubrepo/checkruns.go +++ b/clients/githubrepo/checkruns.go @@ -17,7 +17,6 @@ package githubrepo import ( "context" "fmt" - "strings" "github.com/google/go-github/v38/github" @@ -37,9 +36,6 @@ func (handler *checkrunsHandler) init(ctx context.Context, repourl *repoURL) { } func (handler *checkrunsHandler) listCheckRunsForRef(ref string) ([]clients.CheckRun, error) { - if !strings.EqualFold(handler.repourl.commitSHA, clients.HeadSHA) { - return nil, fmt.Errorf("%w: ListCheckRuns only supported for HEAD queries", clients.ErrUnsupportedFeature) - } checkRuns, _, err := handler.client.Checks.ListCheckRunsForRef( handler.ctx, handler.repourl.owner, handler.repourl.repo, ref, &github.ListCheckRunsOptions{}) if err != nil { diff --git a/clients/githubrepo/statuses.go b/clients/githubrepo/statuses.go index fc595041781..c5907264fb2 100644 --- a/clients/githubrepo/statuses.go +++ b/clients/githubrepo/statuses.go @@ -17,7 +17,6 @@ package githubrepo import ( "context" "fmt" - "strings" "github.com/google/go-github/v38/github" @@ -37,9 +36,6 @@ func (handler *statusesHandler) init(ctx context.Context, repourl *repoURL) { } func (handler *statusesHandler) listStatuses(ref string) ([]clients.Status, error) { - if !strings.EqualFold(handler.repourl.commitSHA, clients.HeadSHA) { - return nil, fmt.Errorf("%w: ListStatuses only supported for HEAD queries", clients.ErrUnsupportedFeature) - } statuses, _, err := handler.client.Repositories.ListStatuses( handler.ctx, handler.repourl.owner, handler.repourl.repo, ref, &github.ListOptions{}) if err != nil {