Commit ba829504 by Crisu83

changed BootMenu to not set a default type

parent 4fccdc2a
......@@ -26,7 +26,7 @@ class BootMenu extends BootBaseMenu
* @var string the menu type.
* Valid values are '', 'tabs' and 'pills'. Defaults to ''.
*/
public $type = self::TYPE_UNSTYLED;
public $type;
/**
* @var boolean whether to stack navigation items.
*/
......@@ -50,9 +50,9 @@ class BootMenu extends BootBaseMenu
$classes = array('nav');
$validTypes = array(self::TYPE_UNSTYLED, self::TYPE_TABS, self::TYPE_PILLS, self::TYPE_LIST);
$validTypes = array(self::TYPE_TABS, self::TYPE_PILLS, self::TYPE_LIST);
if (!empty($this->type) && in_array($this->type, $validTypes))
if (isset($this->type) && in_array($this->type, $validTypes))
$classes[] = 'nav-'.$this->type;
if ($this->type !== self::TYPE_LIST && $this->stacked)
......@@ -179,10 +179,6 @@ class BootMenu extends BootBaseMenu
continue;
}
if (!is_array($item)) {
continue;
}
if (!isset($item['label']))
$item['label'] = '';
......
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