Skip to content

Commit

Permalink
Merge pull request #1 from katzwebservices/fix-line-1-0-value
Browse files Browse the repository at this point in the history
Fix issue when "0" is the only value in the first line
  • Loading branch information
zackkatz committed Jun 19, 2015
2 parents 6760826 + d6aa978 commit b4e964d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Goodby/CSV/Import/Standard/Lexer.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public function parse($filename, InterpreterInterface $interpreter)
setlocale(LC_ALL, 'en_US.UTF-8');

foreach ( $csv as $lineNumber => $line ) {
if ($ignoreHeader && $lineNumber == 0 || (count($line) === 1 && empty($line[0]))) {
if ($ignoreHeader && $lineNumber == 0 || (count($line) === 1 && trim($line[0]) === '')) {
continue;
}
$interpreter->interpret($line);
Expand Down

0 comments on commit b4e964d

Please sign in to comment.