aboutsummaryrefslogtreecommitdiffstats
path: root/include/notifier.php
diff options
context:
space:
mode:
Diffstat (limited to 'include/notifier.php')
-rw-r--r--include/notifier.php19
1 files changed, 17 insertions, 2 deletions
diff --git a/include/notifier.php b/include/notifier.php
index 4435c7497..f0c6d7275 100644
--- a/include/notifier.php
+++ b/include/notifier.php
@@ -118,7 +118,7 @@ function notifier_run($argv, $argc){
$normal_mode = true;
$packet_type = 'undefined';
- if($cmd === 'mail') {
+ if($cmd === 'mail' || $cmd === 'single_mail') {
$normal_mode = false;
$mail = true;
$private = true;
@@ -280,7 +280,7 @@ function notifier_run($argv, $argc){
logger('notifier: target item not forwardable: type ' . $target_item['item_type'], LOGGER_DEBUG);
return;
}
- if(intval($target_item['item_unpublished']) || intval($target_item['item_delayed'])) {
+ if(intval($target_item['item_unpublished']) || intval($target_item['item_delayed']) || intval($target_item['item_hidden'])) {
logger('notifier: target item not published, so not forwardable', LOGGER_DEBUG);
return;
}
@@ -454,6 +454,7 @@ function notifier_run($argv, $argc){
'uplink' => $uplink,
'cmd' => $cmd,
'mail' => $mail,
+ 'single' => (($cmd === 'single_mail' || $cmd === 'single_activity') ? true : false),
'location' => $location,
'request' => $request,
'normal_mode' => $normal_mode,
@@ -550,6 +551,7 @@ function notifier_run($argv, $argc){
'uplink' => $uplink,
'cmd' => $cmd,
'mail' => $mail,
+ 'single' => (($cmd === 'single_mail' || $cmd === 'single_activity') ? true : false),
'location' => $location,
'request' => $request,
'normal_mode' => $normal_mode,
@@ -568,6 +570,19 @@ function notifier_run($argv, $argc){
}
+ // singleton deliveries by definition 'not got zot'.
+ // Single deliveries are other federated networks (plugins) and we're essentially
+ // delivering only to those that have this site url in their abook_instance
+ // and only from within a sync operation. This means if you post from a clone,
+ // and a connection is connected to one of your other clones; assuming that hub
+ // is running it will receive a sync packet. On receipt of this sync packet it
+ // will invoke a delivery to those connections which are connected to just that
+ // hub instance.
+
+ if($cmd === 'single_mail' || $cmd === 'single_activity') {
+ continue;
+ }
+
// default: zot protocol
$hash = random_string();