Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

MDL-38885 form: Fix comments

  • Loading branch information...
commit e8ca6884531a3162cf755d7c09c29e7933c84090 1 parent eb58526
@FMCorz FMCorz authored
Showing with 3 additions and 2 deletions.
  1. +3 −2 lib/formslib.php
View
5 lib/formslib.php
@@ -1512,10 +1512,11 @@ function setTypes($paramtypes) {
* Now if you call this method passing 'foo', along with the submitted values of 'foo':
* array(0 => '1.23', 1 => '10'), you will get an array telling you that the key 0 is a
* FLOAT and 1 is an INT. If you had passed 'foo[1]', along with its value '10', you would
- * get the default value returned.
+ * get the default clean type returned (param $default).
*
* @param string $elementname name of the element.
* @param mixed $value value that should be cleaned.
+ * @param int $default default constant value to be returned (PARAM_...)
* @return string|array constant value or array of constant values (PARAM_...)
*/
public function getCleanType($elementname, $value, $default = PARAM_RAW) {
@@ -1560,7 +1561,7 @@ public function getCleanedValue($value, $type) {
} else if (!is_array($type) && is_array($value)) {
$value = clean_param_array($value, $type, true);
} else {
- throw new coding_exception('Unexpected type or value received in MoodleQuickForm::cleanValue()');
+ throw new coding_exception('Unexpected type or value received in MoodleQuickForm::getCleanedValue()');
}
return $value;
}
Please sign in to comment.
Something went wrong with that request. Please try again.