-
Bug
-
Resolution: Fixed
-
Minor
-
2.0
-
None
-
MOODLE_20_STABLE
-
MOODLE_20_STABLE
Custom menu breaks when nested deeper than 2 levels.
Test menu structure to show the issue
FIRST
- menu1.1
SECOND - menu2.1
- menu2.2
- menu2.2.1
- menu2.2.1.1
THIRD
- menu2.2.1.1
- menu2.2.1
- menu3.1
In line 2346 in the function "convert_text_to_menu_nodes($text)" "$depth = $lastdepth - 1;" depth step back is hard coded to 1 step. That does not work when nesting is more than 2 steps and you need to go back to root.