Expiry post search index entries

This commit is contained in:
Michael 2024-01-21 16:24:59 +00:00
parent 919f97c9a0
commit 6389133575
12 changed files with 397 additions and 299 deletions

View file

@ -261,8 +261,12 @@ class BBCode
if (!empty($media['description']) && (stripos($text, $media['description']) === false)) {
$text .= ' ' . $media['description'];
}
if (in_array($media['type'], [Post\Media::HTML, Post\Media::ACTIVITY]) && !empty($media['name']) && (stripos($text, $media['name']) === false)) {
$text .= ' ' . $media['name'];
if (in_array($media['type'], [Post\Media::HTML, Post\Media::ACTIVITY])) {
foreach (['name', 'author-name', 'publisher-name'] as $key) {
if (!empty($media[$key] && stripos($text, $media[$key]) === false)) {
$text .= ' ' . $media[$key];
}
}
}
}
}