Skip to content

Commit

Permalink
fix(github-actions): properly set the authentication token for featur…
Browse files Browse the repository at this point in the history
…e request action (#306)

The octokit constructor was initially created with an older version of Octokit which supported
providing the token as a property `token`, the property is now expected to be `auth` to properly
use the token for authentication.

PR Close #306
  • Loading branch information
josephperrott committed Nov 16, 2021
1 parent 09a1060 commit 912311a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion github-actions/feature-request/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -11762,7 +11762,7 @@ var require_octokit = __commonJS({
this.options = options;
this._orgMembers = new Set();
this.mockLabels = new Set();
this._octokit = new rest_1.Octokit({ token });
this._octokit = new rest_1.Octokit({ auth: token });
}
get octokit() {
return this._octokit;
Expand Down
2 changes: 1 addition & 1 deletion github-actions/feature-request/src/octokit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ export class OctoKit implements GitHubAPI {
protected params: {repo: string; owner: string},
protected options: {readonly: boolean} = {readonly: false},
) {
this._octokit = new Octokit({token});
this._octokit = new Octokit({auth: token});
}

async *query(query: Query): AsyncIterableIterator<GitHubIssueAPI> {
Expand Down

0 comments on commit 912311a

Please sign in to comment.