diff options
author | Tobias Diekershoff <tobias.diekershoff@gmx.net> | 2012-03-18 07:19:20 +0100 |
---|---|---|
committer | Tobias Diekershoff <tobias.diekershoff@gmx.net> | 2012-03-18 07:19:20 +0100 |
commit | 751e4181e5e875b9f9850700a3687774e4c53ab3 (patch) | |
tree | 87fd3a12a95ceb9aaa696e9968664a272d27799b /include | |
parent | 5fd03583a4f5d8bf0964c7881cbf7a8891513587 (diff) | |
parent | 4bb280bc2f7068f0c1199e9f8119e25278aa3bcb (diff) | |
download | volse-hubzilla-751e4181e5e875b9f9850700a3687774e4c53ab3.tar.gz volse-hubzilla-751e4181e5e875b9f9850700a3687774e4c53ab3.tar.bz2 volse-hubzilla-751e4181e5e875b9f9850700a3687774e4c53ab3.zip |
Merge branch 'master' of https://github.com/friendica/friendica
Diffstat (limited to 'include')
-rwxr-xr-x | include/network.php | 4 | ||||
-rwxr-xr-x | include/queue.php | 11 | ||||
-rwxr-xr-x | include/template_processor.php | 2 | ||||
-rw-r--r-- | include/text.php | 2 |
4 files changed, 12 insertions, 7 deletions
diff --git a/include/network.php b/include/network.php index c72919dd8..22157ff18 100755 --- a/include/network.php +++ b/include/network.php @@ -303,7 +303,7 @@ function webfinger_dfrn($s,&$hcard) { if(! function_exists('webfinger')) { -function webfinger($s) { +function webfinger($s, $debug = false) { $host = ''; if(strstr($s,'@')) { $host = substr($s,strpos($s,'@') + 1); @@ -328,7 +328,7 @@ function webfinger($s) { }} if(! function_exists('lrdd')) { -function lrdd($uri) { +function lrdd($uri, $debug = false) { $a = get_app(); diff --git a/include/queue.php b/include/queue.php index d312b50f5..7e92705be 100755 --- a/include/queue.php +++ b/include/queue.php @@ -61,13 +61,18 @@ function queue_run($argv, $argc){ q("DELETE FROM `queue` WHERE `created` < UTC_TIMESTAMP() - INTERVAL 3 DAY"); } - if($queue_id) + if($queue_id) { $r = q("SELECT `id` FROM `queue` WHERE `id` = %d LIMIT 1", intval($queue_id) ); - else - $r = q("SELECT `id` FROM `queue` WHERE `last` < UTC_TIMESTAMP() - INTERVAL 15 MINUTE "); + } + else { + // For the first 12 hours we'll try to deliver every 15 minutes + // After that, we'll only attempt delivery once per hour. + + $r = q("SELECT `id` FROM `queue` WHERE (( `created` > UTC_TIMESTAMP() - INTERVAL 12 HOUR && `last` < UTC_TIMESTAMP() - INTERVAL 15 MINUTE ) OR ( `last` < UTC_TIMESTAMP() - INTERVAL 1 HOUR ))"); + } if(! count($r)){ return; } diff --git a/include/template_processor.php b/include/template_processor.php index 93bf391c5..4c317efe1 100755 --- a/include/template_processor.php +++ b/include/template_processor.php @@ -203,7 +203,7 @@ $os=$s; $count++; $s = $this->var_replace($s); } - return template_unescape($s); + return $s; } } diff --git a/include/text.php b/include/text.php index cdf82ca87..89acbf9fa 100644 --- a/include/text.php +++ b/include/text.php @@ -20,7 +20,7 @@ function replace_macros($s,$r) { //$a = get_app(); //$a->page['debug'] .= "$tt <br>\n"; - return $r; + return template_unescape($r); }} |