aboutsummaryrefslogtreecommitdiffstats
path: root/include/delivery.php
diff options
context:
space:
mode:
authorFriendika <info@friendika.com>2011-10-21 03:33:34 -0700
committerFriendika <info@friendika.com>2011-10-21 03:33:34 -0700
commit6e76c86ad20c5c9ae3f8f2e2c226c8e22b9a8032 (patch)
treebef69999ba8f63cabbeceeec052807350b24d5f7 /include/delivery.php
parentd1833cabf67b35a10a676d69a1e45fe7aadc31bc (diff)
downloadvolse-hubzilla-6e76c86ad20c5c9ae3f8f2e2c226c8e22b9a8032.tar.gz
volse-hubzilla-6e76c86ad20c5c9ae3f8f2e2c226c8e22b9a8032.tar.bz2
volse-hubzilla-6e76c86ad20c5c9ae3f8f2e2c226c8e22b9a8032.zip
queue api + queue limits
Diffstat (limited to 'include/delivery.php')
-rw-r--r--include/delivery.php18
1 files changed, 3 insertions, 15 deletions
diff --git a/include/delivery.php b/include/delivery.php
index 8318be4dd..a9e629fcf 100644
--- a/include/delivery.php
+++ b/include/delivery.php
@@ -1,5 +1,6 @@
<?php
require_once("boot.php");
+require_once('include/queue_fn.php');
function delivery_run($argv, $argc){
global $a, $db;
@@ -323,14 +324,7 @@ function delivery_run($argv, $argc){
if($deliver_status == (-1)) {
logger('notifier: delivery failed: queuing message');
- // queue message for redelivery
- q("INSERT INTO `queue` ( `cid`, `created`, `last`, `content`)
- VALUES ( %d, '%s', '%s', '%s') ",
- intval($contact['id']),
- dbesc(datetime_convert()),
- dbesc(datetime_convert()),
- dbesc($atom)
- );
+ add_to_queue($contact['id'],NETWORK_DFRN,$atom);
}
break;
@@ -370,13 +364,7 @@ function delivery_run($argv, $argc){
$deliver_status = slapper($owner,$contact['notify'],$slappy);
if($deliver_status == (-1)) {
// queue message for redelivery
- q("INSERT INTO `queue` ( `cid`, `created`, `last`, `content`)
- VALUES ( %d, '%s', '%s', '%s') ",
- intval($contact['id']),
- dbesc(datetime_convert()),
- dbesc(datetime_convert()),
- dbesc($slappy)
- );
+ add_to_queue($contact['id'],NETWORK_OSTATUS,$slappy);
}
}
}