mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 08:26:37 +02:00
checking that there remain $oldwrappedids before deleting them lines 87-..
add if(is_array($oldwrappedids) && count($oldwrappedids)){
This commit is contained in:
parent
2fa9af0d78
commit
0227d32dff
1 changed files with 4 additions and 2 deletions
|
@ -80,8 +80,10 @@ class embedded_cloze_qtype extends default_questiontype {
|
|||
}
|
||||
|
||||
// Delete redundant wrapped questions
|
||||
$oldwrappedids = implode(',', $oldwrappedids);
|
||||
delete_records_select('question', "id IN ($oldwrappedids)");
|
||||
if(is_array($oldwrappedids) && count($oldwrappedids)){
|
||||
$oldwrappedids = implode(',', $oldwrappedids);
|
||||
delete_records_select('question', "id IN ($oldwrappedids)");
|
||||
}
|
||||
|
||||
if (!empty($sequence)) {
|
||||
$multianswer = new stdClass;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue