Skip to content

Commit

Permalink
Return correct variable in stringToEnum
Browse files Browse the repository at this point in the history
  • Loading branch information
ben-v committed Oct 8, 2023
1 parent 57bd3a8 commit 6a59d8e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 61 deletions.
66 changes: 7 additions & 59 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,7 @@ export async function run(): Promise<void> {
function stringToEnum(value: string): VersionReleaseType | null {
const uc: string = value.toUpperCase()
if (Object.values(VersionReleaseType).findIndex(x => x === uc) >= 0) {
return value as VersionReleaseType
return uc as VersionReleaseType
}
return null
}

0 comments on commit 6a59d8e

Please sign in to comment.