mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
Missing addslashes. Merged from MOODLE_17_STABLE.
This commit is contained in:
parent
e995c46e24
commit
f6bde593c7
@ -1932,15 +1932,14 @@
|
||||
if ($categories) {
|
||||
foreach ($categories as $category) {
|
||||
$restoredcategory = get_record('question_categories','id',$category->new_id);
|
||||
$restoredcategory = addslashes_object($restoredcategory);
|
||||
if ($restoredcategory->parent != 0) {
|
||||
//echo 'Parent '.$restoredcategory->parent.' is '; //Debug
|
||||
$idcat = backup_getid($restore->backup_unique_code,'question_categories',$restoredcategory->parent);
|
||||
if ($idcat->new_id) {
|
||||
$restoredcategory->parent = $idcat->new_id;
|
||||
} else {
|
||||
$restoredcategory->parent = 0;
|
||||
}
|
||||
//echo $restoredcategory->parent.' now<br />'; //Debug
|
||||
update_record('question_categories', $restoredcategory);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user