You are here

function panopoly_search_menu_links_discovered_alter in Panopoly Search 8.2

Implements hook_menu_links_discovered_alter().

File

./panopoly_search.module, line 174
Hooks for the panopoly_search module.

Code

function panopoly_search_menu_links_discovered_alter(&$links) {
  $module_handler = \Drupal::moduleHandler();
  if ($module_handler
    ->moduleExists('dblog') && !$module_handler
    ->moduleExists('search')) {
    $links['dblog.search'] = [
      'title' => new TranslatableMarkup('Top search phrases'),
      'route_name' => 'dblog.search',
      'description' => new TranslatableMarkup('View most popular search phrases.'),
      'parent' => 'system.admin_reports',
    ];
  }
  return $links;
}