diff options
author | Friendika <info@friendika.com> | 2011-08-29 00:59:44 -0700 |
---|---|---|
committer | Friendika <info@friendika.com> | 2011-08-29 00:59:44 -0700 |
commit | 177e0e15d73fedd3c58a9d5f9cb7f509bd1da07b (patch) | |
tree | 144a73a9c76d76f604861f63c934d67ee54e4c28 /include/queue.php | |
parent | 391330d95f4b59aaca60ee7e954eaa9e7d2a20c0 (diff) | |
download | volse-hubzilla-177e0e15d73fedd3c58a9d5f9cb7f509bd1da07b.tar.gz volse-hubzilla-177e0e15d73fedd3c58a9d5f9cb7f509bd1da07b.tar.bz2 volse-hubzilla-177e0e15d73fedd3c58a9d5f9cb7f509bd1da07b.zip |
allow zero delivery interval on dedicated servers
Diffstat (limited to 'include/queue.php')
-rw-r--r-- | include/queue.php | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/include/queue.php b/include/queue.php index 1ac1e7d48..5119a65d8 100644 --- a/include/queue.php +++ b/include/queue.php @@ -38,16 +38,15 @@ function queue_run($argv, $argc){ logger('queue: start'); - $interval = intval(get_config('system','delivery_interval')); - if(! $interval) - $interval = 2; + $interval = ((get_config('system','delivery_interval') === false) ? 2 : intval(get_config('system','delivery_interval'))); $r = q("select * from deliverq where 1"); if(count($r)) { foreach($r as $rr) { logger('queue: deliverq'); proc_run('php','include/delivery.php',$rr['cmd'],$rr['item'],$rr['contact']); - @time_sleep_until(microtime(true) + (float) $interval); + if($interval) + @time_sleep_until(microtime(true) + (float) $interval); } } |