Skip to content

Commit

Permalink
Dev: moved $bUseMagicInherit setting out of prepareTemplateRendering()
Browse files Browse the repository at this point in the history
  • Loading branch information
LouisGac committed Aug 9, 2018
1 parent d6ce1f5 commit 1d5c451
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions application/models/TemplateConfiguration.php
Original file line number Diff line number Diff line change
Expand Up @@ -502,19 +502,19 @@ public function prepareTemplateRendering($sTemplateName = '', $iSurveyId = '', $
return self::$aPreparedToRender[$sTemplateName][$iSurveyId][$bUseMagicInherit];
}

$this->bUseMagicInherit = $bUseMagicInherit;
$this->setBasics($sTemplateName, $iSurveyId);
$this->setBasics($sTemplateName, $iSurveyId, $bUseMagicInherit);
$this->setMotherTemplates(); // Recursive mother templates configuration
$this->setThisTemplate(); // Set the main config values of this template
$this->createTemplatePackage($this); // Create an asset package ready to be loaded#
$this->createTemplatePackage($this); // Create an asset package ready to be loaded
$this->getshowpopups();

self::$aPreparedToRender[$sTemplateName][$iSurveyId][$bUseMagicInherit] = $this;
return $this;
}

public function setBasics($sTemplateName = '', $iSurveyId = '')
public function setBasics($sTemplateName = '', $iSurveyId = '', $bUseMagicInherit = false)
{
$this->bUseMagicInherit = $bUseMagicInherit;
$this->sTemplateName = $this->template->name;
$this->setIsStandard(); // Check if it is a CORE template
$this->path = ($this->isStandard)
Expand Down

0 comments on commit 1d5c451

Please sign in to comment.