Skip to content

Commit

Permalink
Merge pull request #532 from City-of-Helsinki/UHF-X_whitescreen
Browse files Browse the repository at this point in the history
prevent whitesceen
  • Loading branch information
rpnykanen authored Jan 15, 2025
2 parents 0da12b9 + 39cc392 commit 87af6b7
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -176,8 +176,11 @@ public static function getDecisionsTitle(): TranslatableMarkup {
* Render array.
*/
public function discussionMinutes(): array {
$build = ['#title' => $this->t('Discussion minutes: @title', ['@title' => $this->policymakerService->getPolicymaker()->get('title')->value])];
return $build;
$policymaker = $this->policymakerService->getPolicymaker();
if (!$policymaker) {
return ['#title' => $this->t('Discussion minutes:')];
}
return ['#title' => $this->t('Discussion minutes: @title', ['@title' => $policymaker->get('title')->value])];
}

/**
Expand Down

0 comments on commit 87af6b7

Please sign in to comment.