Chris@0: getRequirement('_entity_access'); Chris@0: list($entity_type, $operation) = explode('.', $requirement); Chris@0: // If $entity_type parameter is a valid entity, call its own access check. Chris@0: $parameters = $route_match->getParameters(); Chris@0: if ($parameters->has($entity_type)) { Chris@0: $entity = $parameters->get($entity_type); Chris@0: if ($entity instanceof EntityInterface) { Chris@0: return $entity->access($operation, $account, TRUE); Chris@0: } Chris@0: } Chris@0: // No opinion, so other access checks should decide if access should be Chris@0: // allowed or not. Chris@0: return AccessResult::neutral(); Chris@0: } Chris@0: Chris@0: }