1
0
mirror of https://github.com/octoleo/plantuml-server.git synced 2024-06-07 10:50:52 +00:00

Fix the version and end of line issue

This commit is contained in:
Maxime Sinclair 2011-02-17 10:30:21 +01:00
parent 85169a1baf
commit dac7c9f945

View File

@ -148,7 +148,10 @@ public class PlantUmlServlet extends HttpServlet {
StringBuilder plantUmlSource = new StringBuilder(); StringBuilder plantUmlSource = new StringBuilder();
plantUmlSource.append("@startuml\n"); plantUmlSource.append("@startuml\n");
plantUmlSource.append(text); plantUmlSource.append(text);
plantUmlSource.append("\n@enduml"); if (text.endsWith("\n") == false) {
plantUmlSource.append("\n");
}
plantUmlSource.append("@enduml");
final String uml = plantUmlSource.toString(); final String uml = plantUmlSource.toString();
SourceStringReader reader = new SourceStringReader(uml); SourceStringReader reader = new SourceStringReader(uml);
// Write the first image to "os" // Write the first image to "os"
@ -188,4 +191,4 @@ public class PlantUmlServlet extends HttpServlet {
} }
} }
} }