Web\UrlParams: allow to merge single value

This commit is contained in:
Thomas Gelf 2014-09-05 13:35:51 +02:00
parent 51366e2c22
commit 33d2175b77
1 changed files with 3 additions and 0 deletions

View File

@ -181,6 +181,9 @@ class UrlParams
$this->set($k, $v);
}
} else {
if (! is_array($values)) {
$values = array($values);
}
foreach ($values as $value) {
$this->set($param, $value);
}