diff options
author | Mario Vavti <mario@mariovavti.com> | 2017-03-06 22:32:05 +0100 |
---|---|---|
committer | Mario Vavti <mario@mariovavti.com> | 2017-03-06 22:32:44 +0100 |
commit | 6e32be7e43b4458948ff087085da7f216f0acce0 (patch) | |
tree | dfb9bd94dc2d72db1007715c47b2d02da8a24b27 /Zotlabs | |
parent | 4471c45fb75792acbc981b102f4e8eb632780e9d (diff) | |
download | volse-hubzilla-6e32be7e43b4458948ff087085da7f216f0acce0.tar.gz volse-hubzilla-6e32be7e43b4458948ff087085da7f216f0acce0.tar.bz2 volse-hubzilla-6e32be7e43b4458948ff087085da7f216f0acce0.zip |
allow unauthenticated access to public wiki pages
Diffstat (limited to 'Zotlabs')
-rw-r--r-- | Zotlabs/Lib/NativeWikiPage.php | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/Zotlabs/Lib/NativeWikiPage.php b/Zotlabs/Lib/NativeWikiPage.php index 334845290..157c74807 100644 --- a/Zotlabs/Lib/NativeWikiPage.php +++ b/Zotlabs/Lib/NativeWikiPage.php @@ -232,7 +232,11 @@ class NativeWikiPage { } } - $sql_extra = item_permissions_sql($channel_id,$observer_hash); + $sql_extra = ''; + + if($w['wiki']['allow_cid'] || $w['wiki']['allow_gid'] || $w['wiki']['deny_cid'] || $w['wiki']['deny_gid']) + $sql_extra .= item_permissions_sql($channel_id,$observer_hash); + if($revision == (-1)) $sql_extra .= " order by revision desc "; elseif($revision) @@ -284,7 +288,11 @@ class NativeWikiPage { } } - $sql_extra = item_permissions_sql($channel_id,$observer_hash); + $sql_extra = ''; + + if($w['wiki']['allow_cid'] || $w['wiki']['allow_gid'] || $w['wiki']['deny_cid'] || $w['wiki']['deny_gid']) + $sql_extra .= item_permissions_sql($channel_id,$observer_hash); + $sql_extra .= " order by revision desc "; $r = null; |