Commit f4b1b351 authored by catch's avatar catch

Issue #2224553 by longwave, swentel: Add _admin_route for field manager and admin/content.

parent bd28b217
......@@ -8,6 +8,7 @@
namespace Drupal\system\EventSubscriber;
use Drupal\Core\Routing\RouteSubscriberBase;
use Drupal\Core\Routing\RoutingEvents;
use Symfony\Component\Routing\RouteCollection;
/**
......@@ -26,4 +27,19 @@ protected function alterRoutes(RouteCollection $collection, $provider) {
}
}
/**
* {@inheritdoc}
*/
public static function getSubscribedEvents() {
$events = parent::getSubscribedEvents();
// Use a higher priority than \Drupal\field_ui\Routing\RouteSubscriber or
// \Drupal\views\EventSubscriber\RouteSubscriber to ensure we add the
// option to their routes.
// @todo https://drupal.org/node/2158571
$events[RoutingEvents::ALTER] = array('onAlterRoutes', -200);
return $events;
}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment