Skip to content

Commit df15f6b

Browse files
committed
Throw exception for failed match within switch block
1 parent 9c32052 commit df15f6b

16 files changed

Lines changed: 32 additions & 16 deletions

File tree

modules/openapi-generator/src/main/resources/typescript/configuration.mustache

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,8 +132,9 @@ function mergeMiddleware(staticMiddleware: Middleware[], calltimeMiddleware?: Mi
132132
return calltimeMiddleware.concat(staticMiddleware)
133133
case "replace":
134134
return calltimeMiddleware
135+
default:
136+
throw new Error(`Unrecognized middleware merge strategy '${strategy}'`)
135137
}
136-
throw new Error(`Unrecognized middleware merge strategy '${strategy}'`)
137138
}
138139
{{/useInversify}}
139140

samples/client/echo_api/typescript/build/configuration.ts

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

samples/client/others/typescript/builds/array-of-lists/configuration.ts

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

samples/client/others/typescript/builds/enum-single-value/configuration.ts

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

samples/client/others/typescript/builds/null-types-simple/configuration.ts

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

samples/client/others/typescript/builds/with-unique-items/configuration.ts

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

samples/client/others/typescript/encode-decode/build/configuration.ts

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

samples/openapi3/client/petstore/typescript/builds/browser/configuration.ts

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

samples/openapi3/client/petstore/typescript/builds/composed-schemas/configuration.ts

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

samples/openapi3/client/petstore/typescript/builds/default/configuration.ts

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)