Simplyfies AP relaying, fixes relaying of public contacts

This commit is contained in:
Michael 2019-01-17 23:06:27 +00:00
parent 98d44ce7c7
commit d813d72b1a
3 changed files with 38 additions and 16 deletions

View file

@ -88,7 +88,14 @@ class Delivery extends BaseObject
return;
}
$uid = $target_item['contact-uid'];
if (!empty($target_item['contact-uid'])) {
$uid = $target_item['contact-uid'];
} elseif (!empty($target_item['uid'])) {
$uid = $target_item['uid'];
} else {
Logger::log('Only public users for item ' . $item_id, Logger::DEBUG);
return;
}
// avoid race condition with deleting entries
if ($items[0]['deleted']) {