diff --git a/src/premium/github/github.ts b/src/premium/github/github.ts index 55c8ac5..b9512a4 100644 --- a/src/premium/github/github.ts +++ b/src/premium/github/github.ts @@ -187,11 +187,12 @@ export class GitHubApi { const cc = Logger.getCorrelationContext(); interface QueryResult { - repository: { - defaultBranchRef: { - name: string; - } | null; - } | null; + repository: + | { + defaultBranchRef: { name: string } | null | undefined; + } + | null + | undefined; } try { @@ -1288,26 +1289,22 @@ export class GitHubApi { const cc = Logger.getCorrelationContext(); interface QueryResult { - repository: { - defaultBranchRef: - | { - name: string; - target: { oid: string }; - } - | null - | undefined; - }; + repository: + | { + defaultBranchRef: { name: string } | null | undefined; + } + | null + | undefined; } try { - const query = `query getDefaultBranchAndTip( + const query = `query getDefaultBranch( $owner: String! $repo: String! ) { repository(owner: $owner, name: $repo) { defaultBranchRef { name - target { oid } } } }`;