Skip to content

Commit

Permalink
Merge pull request #33949 from sosiouxme/20241213-pr-creator-github-app
Browse files Browse the repository at this point in the history
fix issue #33829: allow pr-creator to work with GH app auth
  • Loading branch information
k8s-ci-robot authored Dec 18, 2024
2 parents 86f9416 + 03e5768 commit 92f9041
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions robots/pr-creator/updater/updater.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const (
type updateClient interface {
UpdatePullRequest(org, repo string, number int, title, body *string, open *bool, branch *string, canModify *bool) error
BotUser() (*github.UserData, error)
FindIssues(query, sort string, asc bool) ([]github.Issue, error)
FindIssuesWithOrg(org, query, sort string, asc bool) ([]github.Issue, error)
}

type ensureClient interface {
Expand Down Expand Up @@ -74,7 +74,7 @@ func updatePRWithQueryTokens(org, repo, title, body, queryTokensString string, g
return nil, fmt.Errorf("bot name: %w", err)
}

issues, err := gc.FindIssues(fmt.Sprintf("is:open is:pr archived:false repo:%s/%s author:%s %s", org, repo, me.Login, queryTokensString), "updated", false)
issues, err := gc.FindIssuesWithOrg(org, fmt.Sprintf("is:open is:pr archived:false repo:%s/%s author:%s %s", org, repo, me.Login, queryTokensString), "updated", false)
if err != nil {
return nil, fmt.Errorf("find issues: %w", err)
} else if len(issues) == 0 {
Expand Down

0 comments on commit 92f9041

Please sign in to comment.