diff options
author | webchick <webchick@24967.no-reply.drupal.org> | 2011-10-02 11:04:56 -0700 |
---|---|---|
committer | webchick <webchick@24967.no-reply.drupal.org> | 2011-10-02 11:04:56 -0700 |
commit | fa5a4a74c835e8542c91eda3edbf8ca5bb0f03c1 (patch) | |
tree | cf7464e456b7433646c77b58ea8a8e08efd60126 /modules | |
parent | f3268d135d0d33c4ca93721ea1a7d426f4fd0427 (diff) | |
download | brdo-fa5a4a74c835e8542c91eda3edbf8ca5bb0f03c1.tar.gz brdo-fa5a4a74c835e8542c91eda3edbf8ca5bb0f03c1.tar.bz2 |
Issue #1273206 by droplet: Access global when it essentially needed.
Diffstat (limited to 'modules')
-rw-r--r-- | modules/node/node.module | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/modules/node/node.module b/modules/node/node.module index b71fb4f7e..51ec8c306 100644 --- a/modules/node/node.module +++ b/modules/node/node.module @@ -2828,8 +2828,6 @@ function node_search_validate($form, &$form_state) { * TRUE if the operation may be performed, FALSE otherwise. */ function node_access($op, $node, $account = NULL) { - global $user; - $rights = &drupal_static(__FUNCTION__, array()); if (!$node || !in_array($op, array('view', 'update', 'delete', 'create'), TRUE)) { @@ -2839,7 +2837,7 @@ function node_access($op, $node, $account = NULL) { } // If no user object is supplied, the access check is for the current user. if (empty($account)) { - $account = $user; + $account = $GLOBALS['user']; } // $node may be either an object or a node type. Since node types cannot be |