gjbarnard / moodle-theme_foundation

Foundation theme for Moodle.
GNU General Public License v3.0
8 stars 0 forks source link

$thiscoursemenu undefined error. #13

Closed turf212 closed 2 years ago

turf212 commented 2 years ago

Line 427 of classes/module/menus_module.php tries to return $output->render_the_menu($thiscoursemenu); in one of the if clauses but $thiscoursemenu is not defined until within a subsequent if clause. When logged on as a user they are then prevented from accessing any courses. Moving the return to within the correct if clause fixes the issue.

https://github.com/gjb2048/moodle-theme_foundation/blob/ff9df675c8b24c100c486b800e2dcc5ce3d27f94/classes/module/menus_module.php#L427

gjb2048 commented 2 years ago

What version of Foundation are you running please?

turf212 commented 2 years ago

Latest version available from the Moodle repositories.

turf212 commented 2 years ago

Moodle 3.9 (if it wasn't clear from the title :) )

gjb2048 commented 2 years ago

@turf212 Thanks for the spot, is a logic issue that I'll fix soon.