mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
Merge branch '4.2' into 4.3
# Conflicts: # src/View/ThemeResourceLoader.php
This commit is contained in:
commit
066ce8e01c
@ -236,10 +236,14 @@ class ThemeResourceLoader implements Flushable
|
||||
foreach ($themePaths as $themePath) {
|
||||
// Join path
|
||||
$pathParts = [ $this->base, $themePath, 'templates', $head, $type, $tail ];
|
||||
$path = Path::join($pathParts) . '.ss';
|
||||
if (file_exists($path)) {
|
||||
$this->getCache()->set($cacheKey, $path);
|
||||
return $path;
|
||||
try {
|
||||
$path = Path::join($pathParts) . '.ss';
|
||||
if (file_exists($path)) {
|
||||
$this->getCache()->set($cacheKey, $path);
|
||||
return $path;
|
||||
}
|
||||
} catch (InvalidArgumentException $e) {
|
||||
// No-op
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user