Permalink
Browse files

Fix codecheck/moodlechecker errors

  • Loading branch information...
1 parent d7238d0 commit d6ebe011b6252f5fa637dfcaf543458c469091cd @mouneyrac mouneyrac committed May 11, 2012
Showing with 18 additions and 6 deletions.
  1. +14 −2 admin/webservice/testclient_forms.php
  2. +2 −2 course/externallib.php
  3. +2 −2 lib/db/services.php
@@ -730,6 +730,10 @@ public function get_params() {
/**
* Form class for create_categories() web service function test.
+ *
+ * @package core_webservice
+ * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
+ * @copyright 2012 Fabio Souto
*/
class core_course_create_categories_form extends moodleform {
/**
@@ -800,9 +804,13 @@ public function get_params() {
return $params;
}
}
-
+
/**
* Form class for delete_categories() web service function test.
+ *
+ * @package core_webservice
+ * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
+ * @copyright 2012 Fabio Souto
*/
class core_course_delete_categories_form extends moodleform {
/**
@@ -878,9 +886,13 @@ public function get_params() {
return $params;
}
}
-
+
/**
* Form class for create_categories() web service function test.
+ *
+ * @package core_webservice
+ * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
+ * @copyright 2012 Fabio Souto
*/
class core_course_update_categories_form extends moodleform {
/**
View
@@ -912,7 +912,6 @@ public static function create_courses($courses) {
require_once($CFG->dirroot . "/course/lib.php");
require_once($CFG->libdir . '/completionlib.php');
-
$params = self::validate_parameters(self::create_courses_parameters(),
array('courses' => $courses));
@@ -1038,7 +1037,8 @@ public static function delete_courses($courseids) {
// Check if the current user has enought permissions.
if (!can_delete_course($courseid)) {
- throw new moodle_exception('cannotdeletecategorycourse', 'error', '', format_string($course->fullname)." (id: $courseid)");
+ throw new moodle_exception('cannotdeletecategorycourse', 'error',
+ '', format_string($course->fullname)." (id: $courseid)");
}
delete_course($course, false);
View
@@ -394,7 +394,7 @@
'type' => 'write',
'capabilities'=> 'moodle:category/manage',
),
-
+
'moodle_course_get_courses' => array(
'classname' => 'core_course_external',
'methodname' => 'get_courses',
@@ -457,7 +457,7 @@
'type' => 'write',
'capabilities'=> 'moodle/category:manage',
),
-
+
'core_course_delete_categories' => array(
'classname' => 'core_course_external',
'methodname' => 'delete_categories',

0 comments on commit d6ebe01

Please sign in to comment.