Define the legacy and modern root template names in the same location (improve locality)

Follow-up to I580fe55ca6aeb35dae8afee41e87172a5a729c7b

Change-Id: Iea8be07c7a86c5ca258ffdfa07fa52713cb1d6d5
This commit is contained in:
AronDemian 2020-04-02 01:55:55 +02:00
parent 177891cc91
commit f2fad08fb7
1 changed files with 3 additions and 5 deletions

View File

@ -43,8 +43,8 @@ class VectorTemplate extends BaseTemplate {
/** @var TemplateParser */
private $templateParser;
/** @var string */
private $templateRoot = 'index';
/** @var string File name of the root (master) template without folder path and extension */
private $templateRoot;
/** @var bool */
private $isLegacy;
@ -63,9 +63,7 @@ class VectorTemplate extends BaseTemplate {
$this->templateParser = $templateParser;
$this->isLegacy = $isLegacy;
if ( $isLegacy ) {
$this->templateRoot = 'legacy';
}
$this->templateRoot = $isLegacy ? 'legacy' : 'index';
}
/**