From 4d9edf1b152f24a770c93b4debddad52d91c6557 Mon Sep 17 00:00:00 2001 From: Dan Poltawski Date: Tue, 13 Oct 2015 19:01:42 +0100 Subject: [PATCH] MDL-51536 webservices: fix invalid param definitions --- group/externallib.php | 2 +- notes/externallib.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/group/externallib.php b/group/externallib.php index d7a5a07c4e5..b530283e871 100644 --- a/group/externallib.php +++ b/group/externallib.php @@ -1310,7 +1310,7 @@ class core_group_external extends external_api { return new external_function_parameters( array( 'cmid' => new external_value(PARAM_INT, 'course module id'), - 'userid' => new external_value(PARAM_INT, 'id of user, empty for current user', VALUE_OPTIONAL, 0) + 'userid' => new external_value(PARAM_INT, 'id of user, empty for current user', VALUE_DEFAULT, 0) ) ); } diff --git a/notes/externallib.php b/notes/externallib.php index 944b2fb1884..b697bf47039 100644 --- a/notes/externallib.php +++ b/notes/externallib.php @@ -466,7 +466,7 @@ class core_notes_external extends external_api { return new external_function_parameters( array( 'courseid' => new external_value(PARAM_INT, 'course id, 0 for SITE'), - 'userid' => new external_value(PARAM_INT, 'user id', VALUE_OPTIONAL), + 'userid' => new external_value(PARAM_INT, 'user id', VALUE_DEFAULT, 0), ) ); }