Skip to content

Commit 9673236

Browse files
committed
Fixes github provider search function
(#3543, #3684)
1 parent 2fe07f9 commit 9673236

File tree

1 file changed

+5
-3
lines changed
  • src/plus/integrations/providers/github

1 file changed

+5
-3
lines changed

src/plus/integrations/providers/github/github.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3040,15 +3040,17 @@ export class GitHubApi implements Disposable {
30403040
const scope = getLogScope();
30413041

30423042
interface SearchResult {
3043-
nodes: GitHubPullRequest[];
3043+
search: {
3044+
nodes: GitHubPullRequest[];
3045+
};
30443046
}
30453047

30463048
try {
30473049
const query = `query searchPullRequests(
30483050
$searchQuery: String!
30493051
$avatarSize: Int
30503052
) {
3051-
search(first: 100, query: $searchQuery, type: ISSUE) {
3053+
search(first: 10, query: $searchQuery, type: ISSUE) {
30523054
nodes {
30533055
...on PullRequest {
30543056
${gqlPullRequestFragment}
@@ -3082,7 +3084,7 @@ export class GitHubApi implements Disposable {
30823084
);
30833085
if (rsp == null) return [];
30843086

3085-
const results = rsp.nodes.map(pr => fromGitHubPullRequest(pr, provider));
3087+
const results = rsp.search.nodes.map(pr => fromGitHubPullRequest(pr, provider));
30863088
return results;
30873089
} catch (ex) {
30883090
throw this.handleException(ex, provider, scope);

0 commit comments

Comments
 (0)