Skip to content
Snippets Groups Projects

addressed issues for cs

Files

@@ -15,6 +15,12 @@ use Symfony\Component\DependencyInjection\ContainerInterface;
class EasyBreadcrumbGeneralSettingsForm extends ConfigFormBase {
use StringTranslationTrait;
/**
* The entity type manager.
*
* @var \Drupal\Core\Entity\EntityTypeManagerInterface
* The entity type manager service.
*/
protected $entityTypeManager;
/**
@@ -28,7 +34,7 @@ class EasyBreadcrumbGeneralSettingsForm extends ConfigFormBase {
* {@inheritdoc}
*/
public static function create(ContainerInterface $container) {
return new static(
return new self(
$container->get('entity_type.manager')
);
}
@@ -145,7 +151,6 @@ class EasyBreadcrumbGeneralSettingsForm extends ConfigFormBase {
'#description' => $this->t('Use menu title instead of raw path component. The real page title setting above will take precedence over this setting. So, one or the other, but not both.'),
'#default_value' => $config->get(EasyBreadcrumbConstants::USE_MENU_TITLE_AS_FALLBACK),
];
$menu_list = array_map(function ($menu) {
return $menu->label();
}, $this->entityTypeManager->getStorage('menu')->loadMultiple());
Loading