- Optimized Input class to ensure that InputFile items are always returned as object as they contain no value.

This commit is contained in:
Simon Sessingø
2016-04-19 14:48:26 +02:00
parent 6b8351f1b8
commit f7af53a9af
+4
View File
@@ -87,6 +87,10 @@ class Input {
if($item !== null) {
if($item instanceof InputFile) {
return $item;
}
if (is_array($item->getValue())) {
return ($key !== null && isset($item->getValue()[$key])) ? $item->getValue()[$key] : $item->getValue();
}