Migration of section pools now works by merging all questions in the pool into one big multi-input question. Preparing questions for merging involves renaming ids to new, part-qualified ids, including updating the choice Ids used as keys in the targeted feedback mapping. This PR corrects a coding error causing incorrect results when merging more than one multiple choice question with targeted feedback. The code to update the single question-global targeted feedback list needs to occur at the end of the routine, so it operates after all constitutent questions have been processed.
This also fixes targeted feedback listing for multi-input questions to omit the correct answer, same as was done for multiple choice questions.
Migration of section pools now works by merging all questions in the pool into one big multi-input question. Preparing questions for merging involves renaming ids to new, part-qualified ids, including updating the choice Ids used as keys in the targeted feedback mapping. This PR corrects a coding error causing incorrect results when merging more than one multiple choice question with targeted feedback. The code to update the single question-global targeted feedback list needs to occur at the end of the routine, so it operates after all constitutent questions have been processed.
This also fixes targeted feedback listing for multi-input questions to omit the correct answer, same as was done for multiple choice questions.