Don't always queue messages

This commit is contained in:
Michael 2018-04-03 12:27:22 +00:00
parent 1a2c771f24
commit e7fb8c04dd

View file

@ -318,10 +318,12 @@ class Delivery {
logger('notifier: dfrn_delivery to '.$contact["url"].' with guid '.$target_item["guid"].' returns '.$deliver_status); logger('notifier: dfrn_delivery to '.$contact["url"].' with guid '.$target_item["guid"].' returns '.$deliver_status);
if ($deliver_status < 200) { if ($deliver_status < 0) {
logger('notifier: delivery failed: queuing message'); logger('notifier: delivery failed: queuing message');
Queue::add($contact['id'], NETWORK_DFRN, $atom, false, $target_item['guid']); Queue::add($contact['id'], NETWORK_DFRN, $atom, false, $target_item['guid']);
}
if ($deliver_status < 200) {
// The message could not be delivered. We mark the contact as "dead" // The message could not be delivered. We mark the contact as "dead"
Contact::markForArchival($contact); Contact::markForArchival($contact);
} else { } else {