Better regex (allow more than two extensions)
This commit is contained in:
parent
31e527151d
commit
eea29dabe8
|
@ -60,7 +60,7 @@ class PhpParallelLint extends Plugin
|
|||
|
||||
if (isset($options['extensions'])) {
|
||||
// Only use if this is a comma delimited list
|
||||
$pattern = '/^[a-z]*,\ *[a-z]*$/';
|
||||
$pattern = '/^([a-z]+)(,\ *[a-z]*)*$/';
|
||||
|
||||
if (preg_match($pattern, $options['extensions'])) {
|
||||
$this->extensions = str_replace(' ', '', $options['extensions']);
|
||||
|
|
Loading…
Reference in a new issue