upgrade twig library

This commit is contained in:
Michael Foster 2013-09-19 16:08:25 +10:00
parent 01857d176a
commit 9c48084f3b
163 changed files with 275 additions and 94 deletions

5
inc/lib/Twig/Compiler.php Normal file → Executable file
View 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);