Skip to content

Commit 6d7e76d

Browse files
Merge branch '3.2'
* 3.2: [3.2] Fix issues reported by static analyse [Workflow] Remove unnecessary method calls
2 parents 111596c + dfcdf33 commit 6d7e76d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

CacheWarmer/TemplatePathsCacheWarmer.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ public function __construct(TemplateFinderInterface $finder, TemplateLocator $lo
3535
{
3636
$this->finder = $finder;
3737
$this->locator = $locator;
38-
$this->filesystem = new Filesystem();
3938
}
4039

4140
/**
@@ -45,10 +44,11 @@ public function __construct(TemplateFinderInterface $finder, TemplateLocator $lo
4544
*/
4645
public function warmUp($cacheDir)
4746
{
47+
$filesystem = new Filesystem();
4848
$templates = array();
4949

5050
foreach ($this->finder->findAllTemplates() as $template) {
51-
$templates[$template->getLogicalName()] = rtrim($this->filesystem->makePathRelative($this->locator->locate($template), $cacheDir), '/');
51+
$templates[$template->getLogicalName()] = rtrim($filesystem->makePathRelative($this->locator->locate($template), $cacheDir), '/');
5252
}
5353

5454
$templates = str_replace("' => '", "' => __DIR__.'/", var_export($templates, true));

0 commit comments

Comments
 (0)