Fix missing media on posts to Mastodon

This commit is contained in:
Michael 2021-05-23 13:29:25 +00:00
parent 4d214bd9cb
commit 36c5e360f6

View file

@ -351,7 +351,7 @@ class Media
foreach ($attachments as $attachment) {
// Only store attachments that are part of the unshared body
if (strpos($unshared_body, $attachment['url']) !== false) {
if (Item::containsLink($unshared_body, $attachment['url'], $attachment['type'])) {
self::insert($attachment);
}
}