Ensure parameter 4 of Post\Media::splitAttachment is a boolean value

This commit is contained in:
Hypolite Petovan 2022-06-20 14:34:02 -04:00
parent 13a5a30b28
commit 88eacbf66e

View file

@ -2831,7 +2831,8 @@ class Item
$shared_uri_id = 0;
$shared_links = [];
}
$attachments = Post\Media::splitAttachments($item['uri-id'], $item['guid'] ?? '', $shared_links, $item['has-media']);
$attachments = Post\Media::splitAttachments($item['uri-id'], $item['guid'] ?? '', $shared_links, $item['has-media'] ?? false);
$item['body'] = self::replaceVisualAttachments($attachments, $item['body'] ?? '');
$item['body'] = preg_replace("/\s*\[attachment .*?\].*?\[\/attachment\]\s*/ism", "\n", $item['body']);