aboutsummaryrefslogtreecommitdiffstats
path: root/include/notifier.php
diff options
context:
space:
mode:
authorredmatrix <redmatrix@redmatrix.me>2015-05-26 21:00:27 -0700
committerredmatrix <redmatrix@redmatrix.me>2015-05-26 21:00:27 -0700
commit07e8fe1b1cbd3a9fbddb95b85c1b372de7fb6e85 (patch)
treed3500f62a6fcff0c4192e47bdd9fcc470b96bb7a /include/notifier.php
parentae69bf54a62629f88a3d1a9ea416c85e23c1b8a4 (diff)
downloadvolse-hubzilla-07e8fe1b1cbd3a9fbddb95b85c1b372de7fb6e85.tar.gz
volse-hubzilla-07e8fe1b1cbd3a9fbddb95b85c1b372de7fb6e85.tar.bz2
volse-hubzilla-07e8fe1b1cbd3a9fbddb95b85c1b372de7fb6e85.zip
Comments need to have some kind of routing instructions.
Diffstat (limited to 'include/notifier.php')
-rw-r--r--include/notifier.php13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/notifier.php b/include/notifier.php
index b82fb41cc..c89c756d9 100644
--- a/include/notifier.php
+++ b/include/notifier.php
@@ -412,6 +412,8 @@ function notifier_run($argv, $argc){
: false
);
+
+
$uplink = false;
// $cmd === 'relay' indicates the owner is sending it to the original recipients
@@ -428,6 +430,17 @@ function notifier_run($argv, $argc){
$uplink = true;
}
+
+ if((! $top_level_post) && (! $relay_to_owner) && (! $uplink) && ($cmd !== 'relay')) {
+
+ // We've been asked to deliver a comment, but it isn't being sent upstream
+ // and the owner isn't delivering it downstream. This is totally unexpected
+ // and shouldn't happen. We will also not allow it to happen.
+
+ logger('Comment being processed with unspecific routing.');
+ return;
+ }
+
if(($relay_to_owner || $uplink) && ($cmd !== 'relay')) {
logger('notifier: followup relay', LOGGER_DEBUG);
$recipients = array(($uplink) ? $parent_item['source_xchan'] : $parent_item['owner_xchan']);