mirror of
https://github.com/moodle/moodle.git
synced 2025-08-08 02:16:41 +02:00
MDL-62388 tool_dataprivacy: Default value if no sensitive data provided
This commit is contained in:
parent
02c7769422
commit
bdc43d7729
1 changed files with 4 additions and 0 deletions
|
@ -478,6 +478,10 @@ class api {
|
||||||
public static function update_purpose(stdClass $record) {
|
public static function update_purpose(stdClass $record) {
|
||||||
self::check_can_manage_data_registry();
|
self::check_can_manage_data_registry();
|
||||||
|
|
||||||
|
if (!isset($record->sensitivedatareasons)) {
|
||||||
|
$record->sensitivedatareasons = '';
|
||||||
|
}
|
||||||
|
|
||||||
$purpose = new purpose($record->id);
|
$purpose = new purpose($record->id);
|
||||||
$purpose->from_record($record);
|
$purpose->from_record($record);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue