You are here

LayoutBuilderIdsRouteSubscriber.php in Layout builder ids 8

Same filename and directory in other branches
  1. 2.0.x src/EventSubscriber/LayoutBuilderIdsRouteSubscriber.php

File

src/EventSubscriber/LayoutBuilderIdsRouteSubscriber.php
View source
<?php

namespace Drupal\layout_builder_ids\EventSubscriber;

use Drupal\Core\Routing\RouteSubscriberBase;
use Symfony\Component\Routing\RouteCollection;

/**
 * Class RouteSubscriber.
 */
class LayoutBuilderIdsRouteSubscriber extends RouteSubscriberBase {

  /**
   * {@inheritdoc}
   */
  protected function alterRoutes(RouteCollection $collection) {
    $configureSectionRoute = $collection
      ->get('layout_builder.configure_section');
    if ($configureSectionRoute) {
      $configureSectionRoute
        ->setDefault('_form', '\\Drupal\\layout_builder_ids\\Form\\ConfigureSectionForm');
    }
  }

}

Classes

Namesort descending Description
LayoutBuilderIdsRouteSubscriber Class RouteSubscriber.