Skip to content

Commit 51945d2

Browse files
committed
remove unnecessary newlines from stdout
1 parent 5c3d4ba commit 51945d2

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/executor.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,10 @@ export default async function execute(
5454
unlinkSync(filepath);
5555

5656
if (stderr) return reject(stderr);
57+
58+
// Remove newline from stdout
59+
if (stdout.endsWith("\n")) stdout = stdout.slice(0, -1);
60+
5761
resolve(stdout);
5862
}
5963
);

0 commit comments

Comments
 (0)