Don't add already queued items from Diaspora to the queue again

This commit is contained in:
Michael 2018-02-08 11:26:24 +00:00
parent af55cd57f3
commit 0093f863fd
7 changed files with 19 additions and 25 deletions

View file

@ -322,7 +322,7 @@ class Delivery {
if ($deliver_status < 0) {
logger('notifier: delivery failed: queuing message');
Queue::add($contact['id'], NETWORK_DFRN, $atom);
Queue::add($contact['id'], NETWORK_DFRN, $atom, false, $target_item['guid']);
// The message could not be delivered. We mark the contact as "dead"
Contact::markForArchival($contact);

View file

@ -145,7 +145,7 @@ class Queue
case NETWORK_DIASPORA:
if ($contact['notify']) {
logger('queue: diaspora_delivery: item ' . $q_item['id'] . ' for ' . $contact['name'] . ' <' . $contact['url'] . '>');
$deliver_status = Diaspora::transmit($owner, $contact, $data, $public, true);
$deliver_status = Diaspora::transmit($owner, $contact, $data, $public, true, 'Queue:' . $q_item['id'], true);
if ($deliver_status == (-1)) {
QueueModel::updateTime($q_item['id']);