Permalink
Browse files

Fixed PHP 5.2 incompatibilty

  • Loading branch information...
1 parent b4d1d62 commit adb5d4f1528f7983975bd27e10f83c4d0f5e5c40 @hason hason committed Sep 26, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/Twig/Loader/Filesystem.php
@@ -163,7 +163,7 @@ protected function findTemplate($name)
$namespace = '__main__';
if (isset($name[0]) && '@' == $name[0]) {
if (false === $pos = strpos($name, '/')) {
- throw new \InvalidArgumentException(sprintf('Malformed namespaced template name "%s" (expecting "@namespace/template_name").', $name));
+ throw new InvalidArgumentException(sprintf('Malformed namespaced template name "%s" (expecting "@namespace/template_name").', $name));
}
$namespace = substr($name, 1, $pos - 1);
@@ -172,7 +172,7 @@ protected function findTemplate($name)
}
if (!isset($this->paths[$namespace])) {
- throw new \Twig_Error_Loader(sprintf('There are no registered paths for namespace "%s".', $namespace));
+ throw new Twig_Error_Loader(sprintf('There are no registered paths for namespace "%s".', $namespace));
}
foreach ($this->paths[$namespace] as $path) {

0 comments on commit adb5d4f

Please sign in to comment.