Skip to content

Commit

Permalink
Reopened and Resolved Issue ID 0000459:
Browse files Browse the repository at this point in the history
  o get_email_address_as_display_text could be improve in order to display '' for null email value.




git-svn-id: http://piwigo.org/svn/trunk@1462 68402e56-0260-453c-a942-63ccdbb3a9ee
  • Loading branch information
rub committed Jul 13, 2006
1 parent 14e73e6 commit f9147af
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
2 changes: 1 addition & 1 deletion admin/user_list.php
Expand Up @@ -823,7 +823,7 @@ function get_filtered_user_list()
'U_PERM' => $perm_url.$local_user['id'],
'USERNAME' => $local_user['username'],
'STATUS' => $lang['user_status_'.$local_user['status']].(($local_user['adviser'] == 'true') ? ' ['.$lang['adviser'].']' : ''),
'EMAIL' => isset($local_user['email']) ? get_email_address_as_display_text($local_user['email']) : '',
'EMAIL' => get_email_address_as_display_text($local_user['email']),
'GROUPS' => $groups_string,
'PROPERTIES' => (isset($local_user['enabled_high']) and ($local_user['enabled_high'] == 'true')) ? $lang['is_high_enabled'] : $lang['is_high_disabled']
)
Expand Down
13 changes: 10 additions & 3 deletions include/functions_user.inc.php
Expand Up @@ -656,13 +656,20 @@ function get_email_address_as_display_text($email_address)
{
global $conf;

if (is_adviser())
if (!isset($email_address) or (trim($email_address) == ''))
{
return 'adviser.mode@'.$_SERVER['SERVER_NAME'];
return '';
}
else
{
return $email_address;
if (is_adviser())
{
return 'adviser.mode@'.$_SERVER['SERVER_NAME'];
}
else
{
return $email_address;
}
}
}

Expand Down

0 comments on commit f9147af

Please sign in to comment.