Skip to content

Commit

Permalink
Accept Octokit.Options in the GitHub constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
jclem committed Sep 5, 2019
1 parent eb4c328 commit e533651
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/github/src/github.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ export class GitHub extends Octokit {
variables?: Variables
) => Promise<GraphQlQueryResponse>

constructor(token: string) {
super({auth: `token ${token}`})
constructor(token: string, opts: Omit<Octokit.Options, 'auth'> = {}) {
super({...opts, auth: `token ${token}`})
this.graphql = defaults({
headers: {authorization: `token ${token}`}
})
Expand Down

0 comments on commit e533651

Please sign in to comment.