diff options
author | friendica <info@friendica.com> | 2014-03-13 17:13:36 -0700 |
---|---|---|
committer | friendica <info@friendica.com> | 2014-03-13 17:13:36 -0700 |
commit | 3cb179aff19d803b91261e410c50b36e4bae1246 (patch) | |
tree | e84880e412390f44e67aff1497562e633deed136 /include/text.php | |
parent | 254885c5ee31b7ab5174161775f5b225fb687e56 (diff) | |
download | volse-hubzilla-3cb179aff19d803b91261e410c50b36e4bae1246.tar.gz volse-hubzilla-3cb179aff19d803b91261e410c50b36e4bae1246.tar.bz2 volse-hubzilla-3cb179aff19d803b91261e410c50b36e4bae1246.zip |
contact_block() not being shown to unauthenticated visitors - even if perms allow. Also separate the permissions logic for this function so that we can have a mini-profile widget and a separate contact_block widget instead of always lumping them together. We probably also should move contact_block() outside of include/text.php as it doesn't really belong there. Just not sure where it belongs - perhaps contact_widgets wouold be a good place.
Diffstat (limited to 'include/text.php')
-rwxr-xr-x | include/text.php | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/text.php b/include/text.php index 839e63f5e..53b92c05f 100755 --- a/include/text.php +++ b/include/text.php @@ -656,6 +656,12 @@ function contact_block() { $o = ''; $a = get_app(); + if(! $a->profile['uid']) + return; + + if(! perm_is_allowed($a->profile['uid'],get_observer_hash(),'view_contacts')) + return; + $shown = get_pconfig($a->profile['uid'],'system','display_friend_count'); if($shown === false) |