Skip to content
Snippets Groups Projects

Drupal standard fix.

1 file
+ 3
3
Compare changes
  • Side-by-side
  • Inline
@@ -65,7 +65,7 @@ class EntityBlock extends BlockBase implements ContainerFactoryPluginInterface {
@@ -65,7 +65,7 @@ class EntityBlock extends BlockBase implements ContainerFactoryPluginInterface {
*
*
* @var array
* @var array
*/
*/
protected $view_mode_options;
protected $viewModeOptions;
/**
/**
* An array of counters for the recursive rendering protection.
* An array of counters for the recursive rendering protection.
@@ -103,7 +103,7 @@ class EntityBlock extends BlockBase implements ContainerFactoryPluginInterface {
@@ -103,7 +103,7 @@ class EntityBlock extends BlockBase implements ContainerFactoryPluginInterface {
$this->entityViewBuilder = $entityTypeManager->getHandler($this->entityTypeName, 'view_builder');
$this->entityViewBuilder = $entityTypeManager->getHandler($this->entityTypeName, 'view_builder');
}
}
$this->view_mode_options = $entityDisplayRepository->getViewModeOptions($this->entityTypeName);
$this->viewModeOptions = $entityDisplayRepository->getViewModeOptions($this->entityTypeName);
$this->loggerFactory = $logger_factory;
$this->loggerFactory = $logger_factory;
}
}
@@ -145,7 +145,7 @@ class EntityBlock extends BlockBase implements ContainerFactoryPluginInterface {
@@ -145,7 +145,7 @@ class EntityBlock extends BlockBase implements ContainerFactoryPluginInterface {
$form['view_mode'] = [
$form['view_mode'] = [
'#type' => 'select',
'#type' => 'select',
'#title' => $this->t('View mode'),
'#title' => $this->t('View mode'),
'#options' => $this->view_mode_options,
'#options' => $this->viewModeOptions,
'#default_value' => $view_mode,
'#default_value' => $view_mode,
];
];
Loading