Skip to content

Commit 1de654f

Browse files
authored
Accept boolean parameters in FunctionParameterList (#371)
1 parent 8593873 commit 1de654f

File tree

1 file changed

+2
-0
lines changed
  • smithy-typescript-codegen/src/main/java/software/amazon/smithy/typescript/codegen

1 file changed

+2
-0
lines changed

smithy-typescript-codegen/src/main/java/software/amazon/smithy/typescript/codegen/CodegenUtils.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,8 @@ static List<String> getFunctionParametersList(Map<String, Object> paramsMap) {
160160
}
161161
} else if (value instanceof String) {
162162
functionParametersList.add(String.format("%s: '%s'", key, value));
163+
} else if (value instanceof Boolean) {
164+
functionParametersList.add(String.format("%s: %s", key, value));
163165
} else {
164166
// Future support for param type should be added in else if.
165167
throw new CodegenException("Plugin function parameters not supported for type "

0 commit comments

Comments
 (0)