aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/delivery.php8
-rw-r--r--include/items.php4
-rw-r--r--include/notifier.php7
3 files changed, 14 insertions, 5 deletions
diff --git a/include/delivery.php b/include/delivery.php
index 46112d78e..e06db6d97 100644
--- a/include/delivery.php
+++ b/include/delivery.php
@@ -123,7 +123,6 @@ function delivery_run($argv, $argc){
if( ! ($icontacts && count($icontacts)))
return;
-
// avoid race condition with deleting entries
if($items[0]['deleted']) {
@@ -269,7 +268,12 @@ function delivery_run($argv, $argc){
if(! $item_contact)
continue;
- $atom .= atom_entry($item,'text',$item_contact,$owner,true);
+ if($normal_mode) {
+ if($item_id == $item['id'])
+ $atom .= atom_entry($item,'text',$item_contact,$owner,true);
+ }
+ else
+ $atom .= atom_entry($item,'text',$item_contact,$owner,true);
}
diff --git a/include/items.php b/include/items.php
index dc08fb3db..93a730d22 100644
--- a/include/items.php
+++ b/include/items.php
@@ -1663,7 +1663,7 @@ function lose_sharer($importer,$contact,$datarray,$item) {
}
-function subscribe_to_hub($url,$importer,$contact,$submode = 'subscribe') {
+function subscribe_to_hub($url,$importer,$contact,$hubmode = 'subscribe') {
if(is_array($importer)) {
$r = q("SELECT `nickname` FROM `user` WHERE `uid` = %d LIMIT 1",
@@ -1686,7 +1686,7 @@ function subscribe_to_hub($url,$importer,$contact,$submode = 'subscribe') {
$params= 'hub.mode=' . $hubmode . '&hub.callback=' . urlencode($push_url) . '&hub.topic=' . urlencode($contact['poll']) . '&hub.verify=async&hub.verify_token=' . $verify_token;
- logger('subscribe_to_hub: subscribing ' . $contact['name'] . ' to hub ' . $url . ' with verifier ' . $verify_token);
+ logger('subscribe_to_hub: ' . $hubmode . ' ' . $contact['name'] . ' to hub ' . $url . ' endpoint: ' . $push_url . ' with verifier ' . $verify_token);
if(! strlen($contact['hub-verify'])) {
$r = q("UPDATE `contact` SET `hub-verify` = '%s' WHERE `id` = %d LIMIT 1",
diff --git a/include/notifier.php b/include/notifier.php
index d1cd1cc73..ceeea2368 100644
--- a/include/notifier.php
+++ b/include/notifier.php
@@ -360,7 +360,12 @@ function notifier_run($argv, $argc){
if(! $contact)
continue;
- $atom .= atom_entry($item,'text',$contact,$owner,true);
+ if($normal_mode) {
+ if($item_id == $item['id'])
+ $atom .= atom_entry($item,'text',$contact,$owner,true);
+ }
+ else
+ $atom .= atom_entry($item,'text',$contact,$owner,true);
if(($top_level) && ($public_message) && ($item['author-link'] === $item['owner-link']) && (! $expire))
$slaps[] = atom_entry($item,'html',$contact,$owner,true);