From 083230c4afdaa042906232c2b116ef4d594575ee Mon Sep 17 00:00:00 2001 From: Holger Veltrup Date: Mon, 25 Mar 2024 07:35:58 +0100 Subject: [PATCH] refactor: reduce code --- src/Service/Indexer/SiteKit/QuoteSectionMatcher.php | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/Service/Indexer/SiteKit/QuoteSectionMatcher.php b/src/Service/Indexer/SiteKit/QuoteSectionMatcher.php index 5107991..c8e64b2 100644 --- a/src/Service/Indexer/SiteKit/QuoteSectionMatcher.php +++ b/src/Service/Indexer/SiteKit/QuoteSectionMatcher.php @@ -37,14 +37,8 @@ public function match(array $path, array $value): string|false /** @var Model $model */ $content = []; - $quote = $model['quote'] ?? ''; - if (is_string($quote)) { - $content[] = $quote; - } - $citation = $model['citation'] ?? ''; - if (is_string($citation)) { - $content[] = $citation; - } + $content[] = $model['quote'] ?? ''; + $content[] = $model['citation'] ?? ''; return implode(' ', $content); }