diff --git a/core/modules/edit/lib/Drupal/edit/Access/EditEntityFieldAccessCheck.php b/core/modules/edit/lib/Drupal/edit/Access/EditEntityFieldAccessCheck.php index 0b43599..cd0a8ef 100644 --- a/core/modules/edit/lib/Drupal/edit/Access/EditEntityFieldAccessCheck.php +++ b/core/modules/edit/lib/Drupal/edit/Access/EditEntityFieldAccessCheck.php @@ -44,7 +44,7 @@ public function accessEditEntityField(EntityInterface $entity, $field_name) { $entity_type = $entity->entityType(); // @todo Generalize to all entity types once http://drupal.org/node/1862750 // is done. - return ($entity_type == 'node' && $node->access('update') && field_access('edit', $field_name, $entity_type, $entity)); + return field_access('edit', $field_name, $entity_type, $entity)); } /** diff --git a/core/modules/file/file.api.php b/core/modules/file/file.api.php index 6a69554..a6d11d5 100644 --- a/core/modules/file/file.api.php +++ b/core/modules/file/file.api.php @@ -223,7 +223,6 @@ function hook_file_delete(Drupal\file\File $file) { */ function hook_file_download_access($field, Drupal\Core\Entity\EntityInterface $entity, Drupal\file\File $file) { if ($entity->entityType() == 'node') { - // @todo revisit later return node_access('view', $entity); } } diff --git a/core/modules/forum/forum.module b/core/modules/forum/forum.module index b30fe74..0b5360d 100644 --- a/core/modules/forum/forum.module +++ b/core/modules/forum/forum.module @@ -175,8 +175,8 @@ function forum_menu_local_tasks(&$data, $router_item, $root_path) { // Loop through all bundles for forum taxonomy vocabulary field. $field = field_info_field('taxonomy_forums'); foreach ($field['bundles']['node'] as $type) { - // @todo revisit later - if (node_access('create', $type)) { + $node = entity_create('node', array('type' => $type)); + if ($node->access('create')) { $links[$type] = array( '#theme' => 'menu_local_action', '#link' => array( diff --git a/core/modules/node/node.module b/core/modules/node/node.module index e99812c..c0b8a90 100644 --- a/core/modules/node/node.module +++ b/core/modules/node/node.module @@ -3558,7 +3558,6 @@ function node_modules_disabled($modules) { */ function node_file_download_access($field, EntityInterface $entity, File $file) { if ($entity->entityType() == 'node') { - // @todo revisit later return node_access('view', $entity); } }