From 71955d8c8a6d666ea40aabb8d580343f61ad8789 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Wed, 1 Feb 2006 14:14:04 +0000 Subject: - Patch #45785 by Markus: Not enabled themes shouldn't appear in admin/themes/settings. --- modules/system/system.module | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'modules/system/system.module') diff --git a/modules/system/system.module b/modules/system/system.module index 879233696..9e0939b25 100644 --- a/modules/system/system.module +++ b/modules/system/system.module @@ -131,9 +131,11 @@ function system_menu($may_cache) { 'type' => MENU_DEFAULT_LOCAL_TASK, 'weight' => -1); foreach (list_themes() as $theme) { - $items[] = array('path' => 'admin/themes/settings/'. $theme->name, 'title' => $theme->name, - 'callback' => 'system_theme_settings', 'callback arguments' => array($theme->name), 'access' => $access, - 'type' => MENU_LOCAL_TASK); + if ($theme->status) { + $items[] = array('path' => 'admin/themes/settings/'. $theme->name, 'title' => $theme->name, + 'callback' => 'system_theme_settings', 'callback arguments' => array($theme->name), 'access' => $access, + 'type' => MENU_LOCAL_TASK); + } } // Modules: -- cgit v1.2.3