From a7e6b3afac49da776f8981effccfe3563efb8c78 Mon Sep 17 00:00:00 2001 From: Michael Stenta Date: Thu, 29 Nov 2018 15:04:29 -0500 Subject: [PATCH] Move farm_theme_preprocess_menu_link() to where it belongs. --- modules/farm/farm_tour/farm_tour.module | 13 ------------- themes/farm_theme/template.php | 13 +++++++++++++ 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/modules/farm/farm_tour/farm_tour.module b/modules/farm/farm_tour/farm_tour.module index c34abcfdb..e886145dc 100644 --- a/modules/farm/farm_tour/farm_tour.module +++ b/modules/farm/farm_tour/farm_tour.module @@ -6,19 +6,6 @@ include_once 'farm_tour.features.inc'; -/** - * Implements hook_preprocess_menu_link(). - */ -function farm_theme_preprocess_menu_link(&$vars) { - - // Give each menu item a CSS class according to its title. - if (!empty($vars['element']['#title'])) { - $title = $vars['element']['#title']; - $class = drupal_html_class($title); - $vars['element']['#localized_options']['attributes']['class'][] = $class; - } -} - /** * Implements hook_farm_help_page(). */ diff --git a/themes/farm_theme/template.php b/themes/farm_theme/template.php index 6fb269303..9d2409501 100644 --- a/themes/farm_theme/template.php +++ b/themes/farm_theme/template.php @@ -23,6 +23,19 @@ function farm_theme_menu_link_alter(&$item) { } } +/** + * Implements hook_preprocess_menu_link(). + */ +function farm_theme_preprocess_menu_link(&$vars) { + + // Give each menu item a CSS class according to its title. + if (!empty($vars['element']['#title'])) { + $title = $vars['element']['#title']; + $class = drupal_html_class($title); + $vars['element']['#localized_options']['attributes']['class'][] = $class; + } +} + /** * Implements hook_preprocess_menu_tree(). */