Bug Fix Spl Flags #130

Merged
merged 1 commit into from Oct 21, 2015

Conversation

Projects
None yet
1 participant
@nyamsprod
Member

nyamsprod commented Oct 21, 2015

  • default flag is now SplFileObject::READ_AHEAD|SplFileObject::SKIP_EMPTY
  • AbstractCsv::__toString is also bug fixed
Bug Fix Spl Flags
- default flag is now SplFileObject::READ_AHEAD|SplFileObject::SKIP_EMPTY
- AbstractCsv::__toString is also bug fixed
@nyamsprod

This comment has been minimized.

Show comment
Hide comment
@nyamsprod

nyamsprod Oct 21, 2015

Member

This PR fixes two bugs related to SplFileObject flags used in the library

  • The default flags are now SplFileObject::READ_AHEAD|SplFileObject::SKIP_EMPTY. So that using foreach will return the expected data even when multiple lines are presents in CSV fields
  • the __toString method needs to normalize the flag usage to output correclty the file. Flags were badly applied which led to missing rows in the output
Member

nyamsprod commented Oct 21, 2015

This PR fixes two bugs related to SplFileObject flags used in the library

  • The default flags are now SplFileObject::READ_AHEAD|SplFileObject::SKIP_EMPTY. So that using foreach will return the expected data even when multiple lines are presents in CSV fields
  • the __toString method needs to normalize the flag usage to output correclty the file. Flags were badly applied which led to missing rows in the output

nyamsprod added a commit that referenced this pull request Oct 21, 2015

@nyamsprod nyamsprod merged commit 924cbde into master Oct 21, 2015

3 checks passed

Scrutinizer No new issues
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@nyamsprod nyamsprod deleted the bugfix/default-options branch Oct 21, 2015

nyamsprod added a commit that referenced this pull request Oct 29, 2015

Improving code quality
- remove the need for the $newline argument in createFromString #132 #130
- improve integer filtering
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment