Skip to content

Commit

Permalink
🎨 Added types
Browse files Browse the repository at this point in the history
  • Loading branch information
nikhilbadyal committed Aug 29, 2023
1 parent dfa744b commit 090cf84
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion __test__/github_fetch_delete.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ async function createRelease(tagName: string = ''): Promise<string> {
})
} catch (error) {
// ignoring as release already exists
info(`Failed to create release ${error}`)
info(`Failed to create release ${tagName} because of ${error}`)
}
return tagName
}
Expand Down
5 changes: 4 additions & 1 deletion src/github.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,10 @@ export async function getReleases(
throw new Error(`Unable to list release: ${error}`)
}
}
export async function deleteRelease(octokit, release: Release): Promise<void> {
export async function deleteRelease(
octokit: InstanceType<typeof GitHub>,
release: Release
): Promise<void> {
info(`Deleting release ${release.id}`)
try {
await octokit.rest.repos.deleteRelease({
Expand Down

0 comments on commit 090cf84

Please sign in to comment.