MDL-35538 forum: take rid of forum_get_separate_modules()

100% incorrect function and not used in codebase at all.
This commit is contained in:
Eloy Lafuente (stronk7) 2012-09-19 21:50:43 +02:00
parent a3ab18c735
commit ed4f7cccc3

View File

@ -7005,27 +7005,6 @@ function forum_get_post_actions() {
return array('add discussion','add post','delete discussion','delete post','move discussion','prune post','update post');
}
/**
* this function returns all the separate forum ids, given a courseid
*
* @global object
* @global object
* @param int $courseid
* @return array
*/
function forum_get_separate_modules($courseid) {
global $CFG,$DB;
$forummodule = $DB->get_record("modules", array("name" => "forum"));
$sql = 'SELECT f.id, f.id FROM {forum} f, {course_modules} cm WHERE
f.id = cm.instance AND cm.module =? AND cm.visible = 1 AND cm.course = ?
AND cm.groupmode ='.SEPARATEGROUPS;
return $DB->get_records_sql($sql, array($forummodule->id, $courseid));
}
/**
* @global object
* @global object