Skip to content

Commit 6ad1418

Browse files
committed
Update style
1 parent 45f087f commit 6ad1418

File tree

1 file changed

+12
-6
lines changed

1 file changed

+12
-6
lines changed

packages/github/src/github.ts

+12-6
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,27 @@
11
// Originally pulled from https://github.com/JasonEtco/actions-toolkit/blob/master/src/github.ts
22
import {graphql} from '@octokit/graphql'
3+
4+
// we need this type to set up a property on the GitHub object
5+
// that has token authorization
6+
// (it is not exported from oktokit by default)
37
import {graphql as GraphQL} from '@octokit/graphql/dist-types/types'
8+
49
import Octokit from '@octokit/rest'
5-
import * as Context from './context'
10+
import * as Context from './context';
611

712
// We need this in order to extend Octokit
8-
Octokit.prototype = new Octokit()
13+
Octokit.prototype = new Octokit();
914

10-
export const context = new Context.Context()
15+
export const context = new Context.Context();
1116

1217
export class GitHub extends Octokit {
13-
graphql: GraphQL
18+
public graphql: GraphQL;
19+
1420
constructor(token: string, opts: Omit<Octokit.Options, 'auth'> = {}) {
15-
super({...opts, auth: `token ${token}`})
21+
super({...opts, auth: `token ${token}`});
1622

1723
this.graphql = graphql.defaults({
1824
headers: {authorization: `token ${token}`}
19-
})
25+
});
2026
}
2127
}

0 commit comments

Comments
 (0)