Did the same thing elsewhere

This commit is contained in:
Tiago Ribeiro
2024-02-05 11:11:44 +00:00
parent fcf2993de0
commit 678ef4b6c0

View File

@@ -143,10 +143,12 @@ def build_write_blanks_text_form(form: [], start_id):
def build_write_blanks_solutions(questions: [], start_id):
solutions = []
for i, q in enumerate(questions, start=start_id):
solution = [q["possible_answers"]] if isinstance(q["possible_answers"], str) else q["possible_answers"]
solutions.append(
{
"id": str(i),
"solution": q["possible_answers"]
"solution": solution
}
)
return solutions