Skip to content

Commit cda10e2

Browse files
committed
Trim whitespace on splitted lines
1 parent 07866ad commit cda10e2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/EDI/Parser.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ public function parse($file2)
105105
if (preg_match($this->stripChars, $line)) {
106106
$this->errors[]="There's a not printable character on line ".$i.": ". $line;
107107
}
108-
$line = preg_replace($this->stripChars, '', $line); //basic sanitization, remove non printable chars
108+
$line = preg_replace($this->stripChars, '', trim($line)); //basic sanitization, remove non printable chars
109109
if (strlen($line)<2) {
110110
unset($file2[$x]);
111111
continue;

0 commit comments

Comments
 (0)