11import { Logger } from "./sentry/logger" ;
2- import { Options as UserOptions } from "./types" ;
2+ import { Options as UserOptions , SetCommitsOptions } from "./types" ;
33import { determineReleaseName } from "./utils" ;
44
55export type NormalizedOptions = ReturnType < typeof normalizeUserOptions > ;
@@ -26,7 +26,10 @@ export function normalizeUserOptions(userOptions: UserOptions) {
2626 create : userOptions . release ?. create ?? true ,
2727 finalize : userOptions . release ?. finalize ?? true ,
2828 vcsRemote : userOptions . release ?. vcsRemote ?? process . env [ "SENTRY_VSC_REMOTE" ] ?? "origin" ,
29- setCommits : userOptions . release ?. setCommits ,
29+ setCommits : userOptions . release ?. setCommits as
30+ | ( SetCommitsOptions & { shouldNotThrowOnFailure ?: boolean } )
31+ | false
32+ | undefined ,
3033 } ,
3134 bundleSizeOptimizations : userOptions . bundleSizeOptimizations ,
3235 reactComponentAnnotation : userOptions . reactComponentAnnotation ,
@@ -48,7 +51,6 @@ export function normalizeUserOptions(userOptions: UserOptions) {
4851 process . env [ "VERCEL_GIT_REPO_OWNER" ]
4952 ) {
5053 options . release . setCommits = {
51- // @ts -expect-error This is fine
5254 shouldNotThrowOnFailure : true ,
5355 commit : process . env [ "VERCEL_GIT_COMMIT_SHA" ] ,
5456 previousCommit : process . env [ "VERCEL_GIT_PREVIOUS_SHA" ] ,
@@ -59,7 +61,6 @@ export function normalizeUserOptions(userOptions: UserOptions) {
5961 } else {
6062 options . release . setCommits = {
6163 shouldNotThrowOnFailure : true ,
62- // @ts -expect-error This is fine
6364 auto : true ,
6465 ignoreEmpty : true ,
6566 ignoreMissing : true ,
0 commit comments