From f7b89bb2f10df317fa97676690eab88170ded040 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Kasper=20Garn=C3=A6s?= <kasper@reload.dk>
Date: Wed, 29 Jun 2011 11:07:08 +0200
Subject: [PATCH] Fix invalid choice in element parent

---
 plugins/content_types/menu_tree/menu_tree.inc |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/plugins/content_types/menu_tree/menu_tree.inc b/plugins/content_types/menu_tree/menu_tree.inc
index e258fe3..c42b284 100644
--- a/plugins/content_types/menu_tree/menu_tree.inc
+++ b/plugins/content_types/menu_tree/menu_tree.inc
@@ -110,6 +110,7 @@ function menu_block_menu_tree_content_type_edit_form(&$form, &$form_state) {
   $form['parent']['#options'] = menu_parent_options(array($conf['menu_name'] => $menus[$conf['menu_name']]), array('mlid' => 0));
   // Hide the Parent item option for the special "active" menu.
   if ($conf['menu_name'] == MENU_TREE__CURRENT_PAGE_MENU) {
+    unset($form['parent']['#options']);
     $form['parent']['#type'] = 'hidden';
     $form['admin_title']['#suffix'] = '<div id="edit-parent-wrapper"><strong>' . t('Parent item:') . '</strong><br />' . t('<em>The menu selected by the page</em> can be customized on the <a href="!url">Menu block settings page</a>.', array('!url' => url('admin/settings/menu_block'))) . '</div>';
   }
-- 
1.7.5.4

