diff --git a/src/Controller/ArticlesController.php b/src/Controller/ArticlesController.php index ccb5c38e..4b7ce06e 100644 --- a/src/Controller/ArticlesController.php +++ b/src/Controller/ArticlesController.php @@ -414,7 +414,7 @@ private function createFirstPage(Request $request, string $id, array $arguments) ); } - if ($item->getType() === 'feature' && $item->getDecisionLetter()) { + if ($item->getType() === 'feature' && $item instanceof ArticleVoR && $item->getDecisionLetter()) { $parts[] = ArticleSection::collapsible( $item->getDecisionLetter()->getId() ?? 'decision-letter', 'Decision letter', @@ -431,7 +431,7 @@ private function createFirstPage(Request $request, string $id, array $arguments) $first = false; } - if ($item->getType() === 'feature' && $item->getAuthorResponse()) { + if ($item->getType() === 'feature'&& $item instanceof ArticleVoR && $item->getAuthorResponse()) { $parts[] = ArticleSection::collapsible( $item->getAuthorResponse()->getId() ?? 'author-response', 'Author response',