#48714, theme_user_picture should take "access user profiles" in to account, patch by frjo
parent
cb49e19e9e
commit
8447307ed2
|
@ -629,7 +629,7 @@ function theme_user_picture($account) {
|
|||
if (isset($picture)) {
|
||||
$alt = t('%user\'s picture', array('%user' => $account->name ? $account->name : variable_get('anonymous', 'Anonymous')));
|
||||
$picture = theme('image', $picture, $alt, $alt, '', false);
|
||||
if (!empty($account->uid)) {
|
||||
if (!empty($account->uid) && user_access('access user profiles')) {
|
||||
$picture = l($picture, "user/$account->uid", array('title' => t('View user profile.')), NULL, NULL, FALSE, TRUE);
|
||||
}
|
||||
|
||||
|
|
|
@ -629,7 +629,7 @@ function theme_user_picture($account) {
|
|||
if (isset($picture)) {
|
||||
$alt = t('%user\'s picture', array('%user' => $account->name ? $account->name : variable_get('anonymous', 'Anonymous')));
|
||||
$picture = theme('image', $picture, $alt, $alt, '', false);
|
||||
if (!empty($account->uid)) {
|
||||
if (!empty($account->uid) && user_access('access user profiles')) {
|
||||
$picture = l($picture, "user/$account->uid", array('title' => t('View user profile.')), NULL, NULL, FALSE, TRUE);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue