Permalink
Browse files

removed json_encode call in Twig_Error when the filename is a string …

…(to avoid the escaping of /)
  • Loading branch information...
1 parent 24eea16 commit 0cbb13d8fab0c30e418c4aa3327e4eec4a5ffe6d @fabpot fabpot committed Nov 7, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/Twig/Error.php
View
@@ -132,7 +132,7 @@ protected function updateRepr()
}
if (null !== $this->filename) {
- $this->message .= sprintf(' in %s', json_encode($this->filename));
+ $this->message .= sprintf(' in %s', is_string($this->filename) ? '"'.$this->filename.'"' : json_encode($this->filename));
}
if ($this->lineno >= 0) {

0 comments on commit 0cbb13d

Please sign in to comment.