From 3c7bc7a377e3d5422f61b92ddf69c4a953ad3d15 Mon Sep 17 00:00:00 2001 From: Florent Bruneau Date: Fri, 17 Sep 2010 14:34:44 +0200 Subject: [PATCH] Don't allow empty flags. Signed-off-by: Florent Bruneau --- classes/plflagset.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/classes/plflagset.php b/classes/plflagset.php index e18adcf..94bd855 100644 --- a/classes/plflagset.php +++ b/classes/plflagset.php @@ -39,7 +39,9 @@ class PlFlagSet $this->sep = $sep; $splitted = explode($sep, $flags); foreach ($splitted as $part) { - $this->values[$part] = true; + if (!empty($part)) { + $this->values[$part] = true; + } } } -- 2.1.4