LegacyStorage: allow weird operator combinations

This allows for "a = b & c & d &" (Neteye writes such config) and for
future extensions like "a = ! b"
This commit is contained in:
Thomas Gelf 2015-10-05 16:37:10 +02:00
parent ac33a83ee2
commit 8a3a04b5f9

View file

@ -249,7 +249,7 @@ class LegacyStorage extends Storage
$op_name = $m[1];
$value = $m[2];
}
$cmps = preg_split('~\s*\\' . $op . '\s*~', $value);
$cmps = preg_split('~\s*\\' . $op . '\s*~', $value, -1, PREG_SPLIT_NO_EMPTY);
foreach ($cmps as & $val) {
if (strpos($val, ';') !== false) {