1
0
mirror of https://github.com/octoleo/plantuml.git synced 2024-11-22 13:05:09 +00:00

ignore trailing ws when reading diagrams from pipes

fixes #349
This commit is contained in:
Beat Christen 2020-07-13 15:46:55 +02:00
parent 55ca84b7c1
commit be5564f5b2

View File

@ -163,10 +163,10 @@ public class Pipe {
break; break;
} }
} }
if (sb.length() == 0) { String source = sb.toString().trim();
if (source.length() == 0) {
return null; return null;
} }
String source = sb.toString();
if (source.startsWith("@start") == false) { if (source.startsWith("@start") == false) {
source = "@startuml\n" + source + "\n@enduml"; source = "@startuml\n" + source + "\n@enduml";
} }