Skip to content
Snippets Groups Projects

Issue #2707689: NodeForm::actions() checks for delete access on new entities

3 files
+ 11
9
Compare changes
  • Side-by-side
  • Inline
Files
3
  • 21d2543a
    Issue #3238485 by daffie: [Symfony 6] Add return type hints to the class... · 21d2543a
    catch authored
    Issue #3238485 by daffie: [Symfony 6] Add return type hints to the class methods of Drupal\Component\DependencyInjection\Container
@@ -127,7 +127,7 @@ public function __construct(array $container_definition = []) {
/**
* {@inheritdoc}
*/
public function get($id, $invalid_behavior = ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE) {
public function get($id, $invalid_behavior = ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE): ?object {
if ($this->hasParameter('_deprecated_service_list')) {
if ($deprecation = $this->getParameter('_deprecated_service_list')[$id] ?? '') {
@trigger_error($deprecation, E_USER_DEPRECATED);
@@ -160,7 +160,7 @@ public function get($id, $invalid_behavior = ContainerInterface::EXCEPTION_ON_IN
// is used, the actual wanted behavior is to re-try getting the service at a
// later point.
if (!$definition) {
return;
return NULL;
}
// Definition is a keyed array, so [0] is only defined when it is a
@@ -180,7 +180,7 @@ public function get($id, $invalid_behavior = ContainerInterface::EXCEPTION_ON_IN
unset($this->services[$id]);
if (ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE !== $invalid_behavior) {
return;
return NULL;
}
throw $e;
@@ -315,14 +315,14 @@ public function set($id, $service) {
/**
* {@inheritdoc}
*/
public function has($id) {
public function has($id): bool {
return isset($this->aliases[$id]) || isset($this->services[$id]) || isset($this->serviceDefinitions[$id]);
}
/**
* {@inheritdoc}
*/
public function getParameter($name) {
public function getParameter($name): array|bool|string|int|float|NULL {
if (!(isset($this->parameters[$name]) || array_key_exists($name, $this->parameters))) {
if (!$name) {
throw new ParameterNotFoundException('');
@@ -337,7 +337,7 @@ public function getParameter($name) {
/**
* {@inheritdoc}
*/
public function hasParameter($name) {
public function hasParameter($name): bool {
return isset($this->parameters[$name]) || array_key_exists($name, $this->parameters);
}
@@ -355,7 +355,7 @@ public function setParameter($name, $value) {
/**
* {@inheritdoc}
*/
public function initialized($id) {
public function initialized($id): bool {
if (isset($this->aliases[$id])) {
$id = $this->aliases[$id];
}
Loading