Delete unused media attachments

This commit is contained in:
Michael 2024-08-24 08:37:56 +00:00
parent af28b82858
commit 425f23bbdc
17 changed files with 459 additions and 372 deletions

View file

@ -979,9 +979,11 @@ class Processor
}
}
$author = Contact::selectFirstAccount(['ap-posting-restricted'], ['id' => $item['author-id']]);
if (!empty($author['ap-posting-restricted'])) {
$item['restrictions'] = $item['restrictions'] | Item::CANT_REPLY;
if (!empty($item['author-id'])) {
$author = Contact::selectFirstAccount(['ap-posting-restricted'], ['id' => $item['author-id']]);
if (!empty($author['ap-posting-restricted'])) {
$item['restrictions'] = $item['restrictions'] | Item::CANT_REPLY;
}
}
$item['location'] = $activity['location'];