Skip to content

Commit

Permalink
issue kubernetes#33829: allow pr-creator to work with GH app auth
Browse files Browse the repository at this point in the history
  • Loading branch information
sosiouxme committed Dec 13, 2024
1 parent 8120bc9 commit 03e5768
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 03e5768

Please sign in to comment.