From f3a87bcf82b68f77cfc2da67c95970b0f70dbcb2 Mon Sep 17 00:00:00 2001 From: Dave Date: Tue, 17 Dec 2024 10:47:06 +0000 Subject: [PATCH] Fix error for POA on Feature Articles https://github.com/elifesciences/issues/issues/9096 --- src/Controller/ArticlesController.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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',