diff options
| author | eric sciple <ericsciple@users.noreply.github.com> | 2021-10-19 09:52:57 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-10-19 09:52:57 -0500 |
| commit | 5ee37f14842852931cb987e86d63ffb679abd036 (patch) | |
| tree | 62fac9cbba0ad2cb177776904836eb5b2e88076c /src/github-api-helper.ts | |
| parent | 6a88a892fe72e01ab1409fe94c4d26e71b939c94 (diff) | |
update dev dependencies and react to new linting rules (#611)
Diffstat (limited to 'src/github-api-helper.ts')
| -rw-r--r-- | src/github-api-helper.ts | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/github-api-helper.ts b/src/github-api-helper.ts index cadd13b..45b979a 100644 --- a/src/github-api-helper.ts +++ b/src/github-api-helper.ts @@ -92,7 +92,10 @@ export async function getDefaultBranch( assert.ok(result, 'default_branch cannot be empty') } catch (err) { // Handle .wiki repo - if (err['status'] === 404 && repo.toUpperCase().endsWith('.WIKI')) { + if ( + (err as any)?.status === 404 && + repo.toUpperCase().endsWith('.WIKI') + ) { result = 'master' } // Otherwise error |
