mirror of
https://github.com/moodle/moodle.git
synced 2025-08-07 09:56:38 +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) {
|
||||
self::check_can_manage_data_registry();
|
||||
|
||||
if (!isset($record->sensitivedatareasons)) {
|
||||
$record->sensitivedatareasons = '';
|
||||
}
|
||||
|
||||
$purpose = new purpose($record->id);
|
||||
$purpose->from_record($record);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue