From ff9051d19fdd764ef5b2a683b7703222c737072c Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Mon, 12 Nov 2012 18:18:55 +0100 Subject: [PATCH] [TwigBundle] fixed typo --- src/Symfony/Bundle/TwigBundle/Extension/CodeExtension.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Symfony/Bundle/TwigBundle/Extension/CodeExtension.php b/src/Symfony/Bundle/TwigBundle/Extension/CodeExtension.php index 63a2be151b..65d51f4773 100644 --- a/src/Symfony/Bundle/TwigBundle/Extension/CodeExtension.php +++ b/src/Symfony/Bundle/TwigBundle/Extension/CodeExtension.php @@ -97,7 +97,7 @@ class CodeExtension extends \Twig_Extension } elseif ('array' === $item[0]) { $formattedValue = sprintf("array(%s)", is_array($item[1]) ? $this->formatArgs($item[1]) : $item[1]); } elseif ('string' === $item[0]) { - $formattedValue = sprintf("'%s'", htmlspecialchars($item[1], ENT_QUOTES, $this->getCharset())); + $formattedValue = sprintf("'%s'", htmlspecialchars($item[1], ENT_QUOTES, $this->charset)); } elseif ('null' === $item[0]) { $formattedValue = 'null'; } elseif ('boolean' === $item[0]) { @@ -105,7 +105,7 @@ class CodeExtension extends \Twig_Extension } elseif ('resource' === $item[0]) { $formattedValue = 'resource'; } else { - $formattedValue = str_replace("\n", '', var_export(htmlspecialchars((string) $item[1], ENT_QUOTES, $this->getCharset()), true)); + $formattedValue = str_replace("\n", '', var_export(htmlspecialchars((string) $item[1], ENT_QUOTES, $this->charset), true)); } $result[] = is_int($key) ? $formattedValue : sprintf("'%s' => %s", $key, $formattedValue);