소스 검색

[WebProfilerBundle] Allow .html.twig in collector template names

Jordi Boggiano 13 년 전
부모
커밋
6ca72cf9ac
1개의 변경된 파일3개의 추가작업 그리고 0개의 파일을 삭제
  1. 3 0
      src/Symfony/Bundle/WebProfilerBundle/Controller/ProfilerController.php

+ 3 - 0
src/Symfony/Bundle/WebProfilerBundle/Controller/ProfilerController.php

@@ -265,6 +265,9 @@ class ProfilerController extends ContainerAware
             }
 
             list($name, $template) = $arguments;
+            if ('.html.twig' === substr($template, -10)) {
+                $template = substr($template, 0, -10);
+            }
             if (!$profiler->has($name) || !$this->container->get('templating')->exists($template.'.html.twig')) {
                 continue;
             }