Commit c4d63fd9 by Braden MacDonald

Avoid a theoretical ZeroDivisionError (shouldn't be possible in practice anyways)

parent 01e7afca
......@@ -124,7 +124,7 @@ class MRQBlock(QuestionnaireAbstractBlock):
'choices': results,
'message': self.message,
'weight': self.weight,
'score': float(score) / len(results),
'score': (float(score) / len(results)) if results else 0,
}
log.debug(u'MRQ submissions result: %s', result)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment