From: Michael Date: Sat, 17 Dec 2022 05:48:09 +0000 (+0000) Subject: Fix: Images must not be removed on preview X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=2e6ab0e31293a8e154561001924ce8d888b32c88;p=friendica.git Fix: Images must not be removed on preview --- diff --git a/src/Model/Item.php b/src/Model/Item.php index 61aeb251ea..33ba8ee7a4 100644 --- a/src/Model/Item.php +++ b/src/Model/Item.php @@ -3016,7 +3016,11 @@ class Item $item['hashtags'] = $tags['hashtags']; $item['mentions'] = $tags['mentions']; - $body = $item['body'] = Post\Media::removeFromEndOfBody($item['body'] ?? ''); + if (!$is_preview) { + $item['body'] = Post\Media::removeFromEndOfBody($item['body'] ?? ''); + } + + $body = $item['body']; $fields = ['uri-id', 'uri', 'body', 'title', 'author-name', 'author-link', 'author-avatar', 'guid', 'created', 'plink', 'network', 'has-media', 'quote-uri-id', 'post-type'];