diff options
author | sirius <sirius83@gmx.de> | 2014-04-16 00:40:01 +0200 |
---|---|---|
committer | sirius <sirius83@gmx.de> | 2014-04-16 00:40:01 +0200 |
commit | b0dc9f13edcbb705e1aa7d0af33bf0351f4d81f4 (patch) | |
tree | 32b053e3f2c95740e316e898d6a2e15688aa4d02 /include/widgets.php | |
parent | 8b8feea12f886a22f7eb66456be7828b7aef455e (diff) | |
parent | efe80bb8e98b32b95d1380633e9ffd834fa82511 (diff) | |
download | volse-hubzilla-b0dc9f13edcbb705e1aa7d0af33bf0351f4d81f4.tar.gz volse-hubzilla-b0dc9f13edcbb705e1aa7d0af33bf0351f4d81f4.tar.bz2 volse-hubzilla-b0dc9f13edcbb705e1aa7d0af33bf0351f4d81f4.zip |
Merging in conflict
Diffstat (limited to 'include/widgets.php')
-rw-r--r-- | include/widgets.php | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/include/widgets.php b/include/widgets.php index 82769d925..678fed833 100644 --- a/include/widgets.php +++ b/include/widgets.php @@ -304,6 +304,9 @@ function widget_archive($arr) { if(! feature_enabled($uid,'archives')) return ''; + if(! perm_is_allowed($uid,get_observer_hash(),'view_stream')) + return ''; + $wall = ((array_key_exists('wall', $arr)) ? intval($arr['wall']) : 0); $style = ((array_key_exists('style', $arr)) ? $arr['style'] : 'select'); @@ -338,6 +341,12 @@ function widget_fullprofile($arr) { function widget_categories($arr) { $a = get_app(); + + + if($a->profile['profile_uid'] && (! perm_is_allowed($a->profile['profile_uid'],get_observer_hash(),'view_stream'))) + return ''; + + $cat = ((x($_REQUEST,'cat')) ? htmlspecialchars($_REQUEST['cat'],ENT_COMPAT,'UTF-8') : ''); $srchurl = $a->query_string; $srchurl = rtrim(preg_replace('/cat\=[^\&].*?(\&|$)/is','',$srchurl),'&'); @@ -350,6 +359,9 @@ function widget_tagcloud_wall($arr) { $a = get_app(); if((! $a->profile['profile_uid']) || (! $a->profile['channel_hash'])) return ''; + if(! perm_is_allowed($a->profile['profile_uid'],get_observer_hash(),'view_stream')) + return ''; + $limit = ((array_key_exists('limit',$arr)) ? intval($arr['limit']) : 50); if(feature_enabled($a->profile['profile_uid'],'tagadelic')) return tagblock('search',$a->profile['profile_uid'],$limit,$a->profile['channel_hash'],ITEM_WALL); |