All pastes #167488 Raw Edit

user_access

public php v1 · immutable
·published 2006-09-12 01:18 UTC
rendered paste body
=== modified file 'modules/user/user.module'--- modules/user/user.module+++ modules/user/user.module@@ -1468,9 +1468,12 @@ function user_view($uid = 0) {   global $user;    $account = user_load(array('uid' => $uid));-  if ($account === FALSE || ($account->access == 0 && !user_access('administer users'))) {+  if ($account === FALSE) {     return drupal_not_found();   }+  if  ($account->status == 0 && !user_access('administer users')) {+    return drupal_access_denied();+  }   // Retrieve and merge all profile fields:   $fields = array();   foreach (module_list() as $module) {