MDL-63626 mod_quiz: Fixed a bug when there was no attempt on the quiz