Join GitHub today
Exception - cannot use object of type stdClass as array #58
Recently upgraded Moodle and we're getting the following error.
running 3.5.1+ (Build: 20180817)
NED Mentor Manager
object of type stdClass as array Debug: \nError code: generalexceptionmessage\n* line 2483 of /blocks/fn_mentor/lib.php: Error thrown\n* line 2488 of /blocks/fn_mentor/lib.php: call to block_fn_mentor_get_selected_courses()\n* line 154 of /blocks/fn_mentor/block_fn_mentor.php: call to block_fn_mentor_get_selected_courses()\n* line 288 of /blocks/moodleblock.class.php: call to block_fn_mentor->get_content()\n* line 230 of /blocks/moodleblock.class.php: call to block_base->formatted_contents()\n* line 1211 of /lib/blocklib.php: call to block_base->get_content_for_output()\n* line 1263 of /lib/blocklib.php: call to block_manager->create_block_contents()\n* line 604 of /lib/outputrenderers.php:
Turn the initial update the site loaded correctly. It wasn't until after the teachers got into the system that this bug appeared. The only way to resolve it was for me to hide the plug in temporarily.
If you'd like to work out some time to debug, please let me know