1
0
Fork 0

Only lines starting with a # should be treated as comments, fixes #3066

pull/3088/head
Jordi Boggiano 2014-06-29 16:17:44 +02:00
parent 02984abf23
commit f53994fcf2
1 changed files with 6 additions and 9 deletions

View File

@ -82,17 +82,14 @@ abstract class BaseExcludeFilter
function ($line) use ($lineParser) {
$line = trim($line);
$commentHash = strpos($line, '#');
if ($commentHash !== false) {
$line = substr($line, 0, $commentHash);
if (!$line || 0 === strpos($line, '#')) {
return;
}
if ($line) {
return call_user_func($lineParser, $line);
}
return null;
}, $lines),
return call_user_func($lineParser, $line);
},
$lines
),
function ($pattern) {
return $pattern !== null;
}