Skip to content

Commit 60e5899

Browse files
committed
updated codegen
1 parent f753121 commit 60e5899

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

modules/swagger-codegen/src/main/java/com/wordnik/swagger/codegen/CodegenConfig.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ public interface CodegenConfig {
2222
String toApiVarName(String name);
2323
String toModelName(String name);
2424
String toParamName(String name);
25+
String escapeText(String text);
2526
String escapeReservedWord(String name);
2627
String getTypeDeclaration(Property p);
2728
String getTypeDeclaration(String name);

modules/swagger-codegen/src/main/java/com/wordnik/swagger/codegen/DefaultGenerator.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,11 @@ public List<File> generate() {
6767
config.additionalProperties().put("appVersion", info.getVersion());
6868
}
6969
if (info.getDescription() != null) {
70-
config.additionalProperties().put("appDescription", info.getDescription());
70+
System.out.println(info.getDescription());
71+
System.out.println("escaped");
72+
System.out.println(config.escapeText(info.getDescription()));
73+
config.additionalProperties().put("appDescription",
74+
config.escapeText(info.getDescription()));
7175
}
7276
if (info.getContact() != null) {
7377
Contact contact = info.getContact();

modules/swagger-codegen/src/main/java/com/wordnik/swagger/codegen/languages/SpringfoxServerCodegen.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ public class SpringfoxServerCodegen extends JavaClientCodegen implements Codegen
2020
protected String configPackage = "";
2121

2222
public CodegenType getTag() {
23-
return CodegenType.OTHER;
23+
return CodegenType.SERVER;
2424
}
2525

2626
public String getName() {

0 commit comments

Comments
 (0)