zendframework / zend-diactoros

PSR-7 HTTP Message implementation
BSD 3-Clause "New" or "Revised" License
1.55k stars 152 forks source link

reduce $crFound check at AbstractSerializer::getLine() #309

Closed samsonasik closed 6 years ago

weierophinney commented 6 years ago

I disagree with this change. The four distinct conditionals in the while loop are for a reason: to detail the specific carriage return/line feed combinations we scan for, and the impact each has when detecting a line. Moving one part of the conditional inside the other makes understanding the combinations more difficult.