From fdcf950616d839583afc1c28469139e2e5fe29ca Mon Sep 17 00:00:00 2001 From: MonsterDruide1 <5958456@gmail.com> Date: Fri, 7 Oct 2022 13:31:38 +0200 Subject: [PATCH] Script: Only export non-empty lines --- src/main/java/io/github/jadefalke2/Script.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/io/github/jadefalke2/Script.java b/src/main/java/io/github/jadefalke2/Script.java index 255e35b..cfe7171 100644 --- a/src/main/java/io/github/jadefalke2/Script.java +++ b/src/main/java/io/github/jadefalke2/Script.java @@ -111,7 +111,7 @@ public boolean closeScript(){ * @return the script as a string */ public String getFull (){ - return IntStream.range(0, inputLines.size()).mapToObj(i -> inputLines.get(i).getFull(i)+"\n").collect(Collectors.joining()); + return IntStream.range(0, inputLines.size()).filter(i -> !inputLines.get(i).isEmpty()).mapToObj(i -> inputLines.get(i).getFull(i)+"\n").collect(Collectors.joining()); } /**