mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 05:58:34 +01:00
MDL-57273 exporter: Clarify why contextname needs to be PARAM_RAW
This commit is contained in:
parent
547801a411
commit
c59e531301
@ -61,7 +61,8 @@ class cohort_summary_exporter extends \core\external\exporter {
|
||||
public static function define_other_properties() {
|
||||
return array(
|
||||
'contextname' => array(
|
||||
'type' => PARAM_TEXT
|
||||
// The method context::get_context_name() already formats the string, and may return HTML.
|
||||
'type' => PARAM_RAW
|
||||
),
|
||||
);
|
||||
}
|
||||
|
@ -74,6 +74,9 @@ class competency_framework_exporter extends \core\external\persistent_exporter {
|
||||
'competenciescount' => array(
|
||||
'type' => PARAM_INT
|
||||
),
|
||||
|
||||
// Both contexts need to be PARAM_RAW because the method context::get_context_name()
|
||||
// already applies the formatting and thus could return HTML content.
|
||||
'contextname' => array(
|
||||
'type' => PARAM_RAW
|
||||
),
|
||||
|
Loading…
x
Reference in New Issue
Block a user