mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
MDL-44985 libraries: Final deprecation of conditional classes and apis
This commit is contained in:
parent
2d84748c26
commit
e56e8e3a0e
10 changed files with 8 additions and 749 deletions
|
@ -3944,22 +3944,13 @@ function ajaxenabled(array $browsers = null) {
|
|||
}
|
||||
|
||||
/**
|
||||
* Determine whether a course module is visible within a course,
|
||||
* this is different from instance_is_visible() - faster and visibility for user
|
||||
* Determine whether a course module is visible within a course.
|
||||
*
|
||||
* @global object
|
||||
* @global object
|
||||
* @uses DEBUG_DEVELOPER
|
||||
* @uses CONTEXT_MODULE
|
||||
* @param object $cm object
|
||||
* @param int $userid empty means current user
|
||||
* @return bool Success
|
||||
* @deprecated Since Moodle 2.7
|
||||
* @deprecated Since Moodle 2.7 MDL-44070
|
||||
*/
|
||||
function coursemodule_visible_for_user($cm, $userid=0) {
|
||||
debugging('coursemodule_visible_for_user() deprecated since Moodle 2.7. ' .
|
||||
'Replace with \core_availability\info_module::is_user_visible().');
|
||||
return \core_availability\info_module::is_user_visible($cm, $userid, false);
|
||||
throw new coding_exception('coursemodule_visible_for_user() can not be used any more,
|
||||
please use \core_availability\info_module::is_user_visible()');
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue