aboutsummaryrefslogtreecommitdiffstats
path: root/include/zot.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2014-08-06 21:16:24 -0700
committerfriendica <info@friendica.com>2014-08-06 21:16:24 -0700
commit2cff122d6ffcd47e42593d22c1c8d19f45ee91ef (patch)
treea1607f94448ba93586a84c347dd52f226b58eba5 /include/zot.php
parent86bccf35a24019830fc54ac781f985d9add6eddf (diff)
downloadvolse-hubzilla-2cff122d6ffcd47e42593d22c1c8d19f45ee91ef.tar.gz
volse-hubzilla-2cff122d6ffcd47e42593d22c1c8d19f45ee91ef.tar.bz2
volse-hubzilla-2cff122d6ffcd47e42593d22c1c8d19f45ee91ef.zip
public scope delivery issues
Diffstat (limited to 'include/zot.php')
-rw-r--r--include/zot.php14
1 files changed, 11 insertions, 3 deletions
diff --git a/include/zot.php b/include/zot.php
index 971f91a3c..1e38b8b49 100644
--- a/include/zot.php
+++ b/include/zot.php
@@ -1200,6 +1200,12 @@ function zot_import($arr, $sender_url) {
continue;
}
+ // It's a specifically targetted post. If we were sent a public_scope hint (likely),
+ // get rid of it so that it doesn't get stored and cause trouble.
+
+ if(array_key_exists('message',$i) && array_key_exists('public_scope',$i['message']))
+ unset($i['message']['public_scope']);
+
$deliveries = $r;
// We found somebody on this site that's in the recipient list.
@@ -1207,9 +1213,11 @@ function zot_import($arr, $sender_url) {
}
else {
if(($i['message']) && (array_key_exists('flags',$i['message'])) && (in_array('private',$i['message']['flags']))) {
- // This should not happen but until we can stop it...
- logger('private message was delivered with no recipients.');
- continue;
+ if(array_key_exists('public_scope',$i['message']) && $i['message']['public_scope'] === 'public') {
+ // This should not happen but until we can stop it...
+ logger('private message was delivered with no recipients.');
+ continue;
+ }
}
logger('public post');