Commit 11ed319c by Braden MacDonald

Fix: confusing behaviour of max_attempts when changing mode

parent ecb5d308
...@@ -621,15 +621,6 @@ class MentoringBlock(XBlock, StepParentMixin, StudioEditableXBlockMixin, StudioC ...@@ -621,15 +621,6 @@ class MentoringBlock(XBlock, StepParentMixin, StudioEditableXBlockMixin, StudioC
html += child.render('mentoring_view', {}).content # TODO: frament_text_rewriting ? html += child.render('mentoring_view', {}).content # TODO: frament_text_rewriting ?
return html return html
def clean_studio_edits(self, data):
"""
Given POST data dictionary 'data', clean the data before validating it.
e.g. fix capitalization, remove trailing spaces, etc.
"""
if data.get('mode') == 'assessment' and 'max_attempts' not in data:
# assessment has a default of 2 max_attempts
data['max_attempts'] = 2
def validate(self): def validate(self):
""" """
Validates the state of this XBlock except for individual field values. Validates the state of this XBlock except for individual field values.
......
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