forked from leftypol/leftypol
upgrade twig library
This commit is contained in:
parent
01857d176a
commit
9c48084f3b
163 changed files with 275 additions and 94 deletions
5
inc/lib/Twig/Compiler.php
Normal file → Executable file
5
inc/lib/Twig/Compiler.php
Normal file → Executable file
|
@ -180,11 +180,12 @@ class Twig_Compiler implements Twig_CompilerInterface
|
|||
$this->raw($value ? 'true' : 'false');
|
||||
} elseif (is_array($value)) {
|
||||
$this->raw('array(');
|
||||
$i = 0;
|
||||
$first = true;
|
||||
foreach ($value as $key => $value) {
|
||||
if ($i++) {
|
||||
if (!$first) {
|
||||
$this->raw(', ');
|
||||
}
|
||||
$first = false;
|
||||
$this->repr($key);
|
||||
$this->raw(' => ');
|
||||
$this->repr($value);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue