aboutsummaryrefslogtreecommitdiffstats
path: root/include/zot.php
diff options
context:
space:
mode:
authorAndrew Manning <tamanning@zoho.com>2016-08-27 06:52:01 -0400
committerAndrew Manning <tamanning@zoho.com>2016-08-27 06:52:01 -0400
commitddfc5209d3a8a4b10f66b0ae0497a269ff2bdde1 (patch)
tree80936d2335aca91c1a3b828c234ae736c811d22b /include/zot.php
parent420aa4bc44a2fdf707b3964582258809f978ea2d (diff)
parentaea2fa1629692cc29f1070a66fbde9fb9ae837a6 (diff)
downloadvolse-hubzilla-ddfc5209d3a8a4b10f66b0ae0497a269ff2bdde1.tar.gz
volse-hubzilla-ddfc5209d3a8a4b10f66b0ae0497a269ff2bdde1.tar.bz2
volse-hubzilla-ddfc5209d3a8a4b10f66b0ae0497a269ff2bdde1.zip
Merge remote-tracking branch 'upstream/dev' into website-export. Added attach_move() to include/attach.php.
Diffstat (limited to 'include/zot.php')
-rw-r--r--include/zot.php18
1 files changed, 6 insertions, 12 deletions
diff --git a/include/zot.php b/include/zot.php
index c3c924113..6187e8a61 100644
--- a/include/zot.php
+++ b/include/zot.php
@@ -3785,20 +3785,14 @@ function zotinfo($arr) {
if($role === 'forum' || $role === 'repository') {
$public_forum = true;
}
- elseif($ztarget_hash) {
+ else {
// check if it has characteristics of a public forum based on custom permissions.
- $t = q("select * from abconfig where abconfig.cat = 'my_perms' and abconfig.chan = %d and abconfig.xchan = '%s' and abconfig.k in ('tag_deliver', 'send_stream') ",
- intval($e['channel_id']),
- dbesc($ztarget_hash)
- );
-
- $ch = 0;
-
- if($t) {
- foreach($t as $tt) {
- if($tt['k'] == 'tag_deliver' && $tt['v'] == 1)
+ $m = \Zotlabs\Access\Permissions::FilledAutoperms($e['channel_id']);
+ if($m) {
+ foreach($m as $k => $v) {
+ if($k == 'tag_deliver' && intval($v) == 1)
$ch ++;
- if($tt['k'] == 'send_stream' && $tt['v'] == 0)
+ if($k == 'send_stream' && intval($v) == 0)
$ch ++;
}
if($ch == 2)