From e92c39cadcb8799bce28743b7df4644acf79b6fb Mon Sep 17 00:00:00 2001 From: Petr Skoda Date: Fri, 17 Sep 2010 12:04:48 +0000 Subject: [PATCH] improved phpdocs --- course/lib.php | 13 +++++++------ lib/accesslib.php | 9 ++++----- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/course/lib.php b/course/lib.php index c1e0fe2995c..4b0697ebba5 100644 --- a/course/lib.php +++ b/course/lib.php @@ -1752,7 +1752,7 @@ function rebuild_course_cache($courseid=0, $clearonly=false) { * Gets the child categories of a given coures category. Uses a static cache * to make repeat calls efficient. * - * @param unknown_type $parentid the id of a course category. + * @param int $parentid the id of a course category. * @return array all the child course categories. */ function get_child_categories($parentid) { @@ -3093,7 +3093,7 @@ function course_allowed_module($course,$mod) { /** * Recursively delete category including all subcategories and courses. - * @param object $category + * @param stdClass $category * @param boolean $showfeedback display some notices * @return array return deleted courses */ @@ -3192,7 +3192,8 @@ function category_delete_move($category, $newparentid, $showfeedback=true) { * Efficiently moves many courses around while maintaining * sortorder in order. * - * @param $courseids is an array of course ids + * @param array $courseids is an array of course ids + * @param int $categoryid * @return bool success */ function move_courses($courseids, $categoryid) { @@ -3234,7 +3235,7 @@ function move_courses($courseids, $categoryid) { /** * Hide course category and child course and subcategories - * @param $category + * @param stdClass $category * @return void */ function course_category_hide($category) { @@ -3258,7 +3259,7 @@ function course_category_hide($category) { /** * Show course category and child course and subcategories - * @param $category + * @param stdClass $category * @return void */ function course_category_show($category) { @@ -3531,7 +3532,7 @@ function create_course($data, $editoroptions = NULL) { mark_context_dirty($context->path); // Save any custom role names. - save_local_role_names($course->id, $data); + save_local_role_names($course->id, (array)$data); // set up enrolments enrol_course_updated(true, $course, $data); diff --git a/lib/accesslib.php b/lib/accesslib.php index 1c047b5a2c1..7675457a1d5 100755 --- a/lib/accesslib.php +++ b/lib/accesslib.php @@ -5029,7 +5029,7 @@ function sort_by_roleassignment_authority($users, $context, $roles=array(), $sor * * @global object * @param int $roleid (can also be an array of ints!) - * @param object $context + * @param stdClass $context * @param bool $parent if true, get list of users assigned in higher context too * @param string $fields fields from user (u.) , role assignment (ra) or role (r.) * @param string $sort sort from user (u.) , role assignment (ra) or role (r.) @@ -5038,7 +5038,7 @@ function sort_by_roleassignment_authority($users, $context, $roles=array(), $sor * @param mixed $limitfrom defaults to '' * @param mixed $limitnum defaults to '' * @param string $extrawheretest defaults to '' - * @param string $whereparams defaults to '' + * @param string|array $whereparams defaults to '' * @return array */ function get_role_users($roleid, $context, $parent=false, $fields='', @@ -5719,9 +5719,8 @@ function build_context_path($force=false) { * DB efficient as possible. This op can have a * massive impact in the DB. * - * @global object - * @param obj $current context obj - * @param obj $newparent new parent obj + * @param stdClass $current context obj + * @param stdClass $newparent new parent obj * */ function context_moved($context, $newparent) {