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:05 +0100 |
commit | 9e44b0727513d820336cd4c51350d62b13cf8479 (patch) | |
tree | f6bd2df965b36e0d054112398e8022f8af90e2a3 /Zotlabs | |
parent | 99e681c09faa245f9ac06a0a502c3c89a49490cb (diff) | |
download | volse-hubzilla-9e44b0727513d820336cd4c51350d62b13cf8479.tar.gz volse-hubzilla-9e44b0727513d820336cd4c51350d62b13cf8479.tar.bz2 volse-hubzilla-9e44b0727513d820336cd4c51350d62b13cf8479.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 25e454cb7..e9f8a32c9 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; |