Skip to content

Commit

Permalink
Add missing underscores for PascalCase enum values OpenAPITools#4837
Browse files Browse the repository at this point in the history
  • Loading branch information
renatomameli committed May 7, 2024
1 parent dec8a43 commit 1d4bb17
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2039,7 +2039,7 @@ public String toEnumVarName(String value, String datatype) {
}

// string
String var = value.replaceAll("\\W+", "_").toUpperCase(Locale.ROOT);
String var = underscore(value.replaceAll("\\W+", "_")).toUpperCase(Locale.ROOT);
if (var.matches("\\d.*")) {
var = "_" + var;
}
Expand Down

0 comments on commit 1d4bb17

Please sign in to comment.