aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Zotlabs/Module/Item.php6
-rwxr-xr-xinclude/items.php4
2 files changed, 10 insertions, 0 deletions
diff --git a/Zotlabs/Module/Item.php b/Zotlabs/Module/Item.php
index 3f857030b..fba2ef7a4 100644
--- a/Zotlabs/Module/Item.php
+++ b/Zotlabs/Module/Item.php
@@ -830,6 +830,12 @@ class Item extends \Zotlabs\Web\Controller {
$datarray['plink'] = $plink;
$datarray['route'] = $route;
+
+ // A specific ACL over-rides public_policy completely
+
+ if(! empty_acl($datarray))
+ $datarray['public_policy'] = '';
+
if($iconfig)
$datarray['iconfig'] = $iconfig;
diff --git a/include/items.php b/include/items.php
index 50f663836..7faa1b9ec 100755
--- a/include/items.php
+++ b/include/items.php
@@ -969,6 +969,10 @@ function import_author_unknown($x) {
return false;
}
+function empty_acl($item) {
+ return (($item['allow_cid'] === EMPTY_STR && $item['allow_gid'] === EMPTY_STR && $item['deny_cid'] === EMPTY_STR && $item['deny_gid'] === EMPTY_STR) ? true : false);
+}
+
function encode_item($item,$mirror = false) {
$x = array();
$x['type'] = 'activity';