Skip to content

Commit

Permalink
Set current site state for overwritten site-wide home pages
Browse files Browse the repository at this point in the history
  • Loading branch information
CatoTH committed Sep 15, 2024
1 parent 29f91e1 commit d2d9d37
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion controllers/Base.php
Original file line number Diff line number Diff line change
Expand Up @@ -540,6 +540,7 @@ public function loadConsultation(string $subdomain, string $consultationId = '',
{
if (is_null($this->site)) {
$this->site = Site::findOne(['subdomain' => $subdomain]);
UrlHelper::setCurrentSite($this->site);
}

if ($this instanceof ConsultationController && $this->action->id === 'home') {
Expand Down Expand Up @@ -577,7 +578,6 @@ public function loadConsultation(string $subdomain, string $consultationId = '',
}

UrlHelper::setCurrentConsultation($this->consultation);
UrlHelper::setCurrentSite($this->site);

$this->layoutParams->setConsultation($this->consultation);

Expand Down

0 comments on commit d2d9d37

Please sign in to comment.