mirror of
https://github.com/getgrav/grav.git
synced 2026-05-06 23:47:45 +02:00
Returning empty array if input wasn't provided.
This commit is contained in:
@@ -231,6 +231,10 @@ class TwigExtension extends \Twig_Extension
|
||||
{
|
||||
$output = [];
|
||||
|
||||
if (!$input) {
|
||||
return $output;
|
||||
}
|
||||
|
||||
foreach ($input as $key => $row) {
|
||||
$output[$key] = $row[$filter];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user