Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Context instances/other functions need updated for newer Moodle versions #8

Open
logan-reynolds opened this issue Nov 14, 2017 · 0 comments

Comments

@logan-reynolds
Copy link

When viewing the page with this plugin installed and debug enabled, I'm seeing the following which indicates the context instance calls need to be updated to the newer format, along with checking other M30+ complant functions to make sure no warnings are being thrown and the plugin is operating as expected:

Warning: Creating default object from empty value in /var/www/html/TOTARA_100_STABLE/blocks/course_appointments/block_course_appointments.php on line 124
get_context_instance() is deprecated, please use context_xxxx::instance() instead.

line 282 of /lib/deprecatedlib.php: call to debugging()
line 125 of /blocks/course_appointments/block_course_appointments.php: call to get_context_instance()
line 288 of /blocks/moodleblock.class.php: call to block_course_appointments->get_content()
line 230 of /blocks/moodleblock.class.php: call to block_base->formatted_contents()
line 1177 of /lib/blocklib.php: call to block_base->get_content_for_output()
line 1232 of /lib/blocklib.php: call to block_manager->create_block_contents()
line 354 of /lib/blocklib.php: call to block_manager->ensure_content_created()
line 34 of /theme/basis/layout/default.php: call to block_manager->region_has_content()
line 849 of /lib/outputrenderers.php: call to include()
line 779 of /lib/outputrenderers.php: call to core_renderer->render_page_layout()
line 252 of /course/view.php: call to core_renderer->header()

Did you remember to call setType() for 'courseid'? Defaulting to PARAM_RAW cleaning.

line 1379 of /lib/formslib.php: call to debugging()
line 352 of /lib/formslib.php: call to moodleform->detectMissingSetType()
line 258 of /lib/formslib.php: call to moodleform->_process_submission()
line 133 of /blocks/course_appointments/block_course_appointments.php: call to moodleform->__construct()
line 288 of /blocks/moodleblock.class.php: call to block_course_appointments->get_content()
line 230 of /blocks/moodleblock.class.php: call to block_base->formatted_contents()
line 1177 of /lib/blocklib.php: call to block_base->get_content_for_output()
line 1232 of /lib/blocklib.php: call to block_manager->create_block_contents()
line 354 of /lib/blocklib.php: call to block_manager->ensure_content_created()
line 34 of /theme/basis/layout/default.php: call to block_manager->region_has_content()
line 849 of /lib/outputrenderers.php: call to include()
line 779 of /lib/outputrenderers.php: call to core_renderer->render_page_layout()
line 252 of /course/view.php: call to core_renderer->header()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant