Skip to content
Snippets Groups Projects
Unverified Commit 494105f1 authored by Attiya Ishaque's avatar Attiya Ishaque Committed by GitHub
Browse files

Merge pull request #18143 from edx/ai/EDUCATOR-2825-course-outline

Fix inconsistency progress between Unit and Course Outline.
parents f32b3542 b8fdc2ce
No related merge requests found
......@@ -91,7 +91,10 @@ def get_course_outline_block_tree(request, course_id):
if block['children'][idx]['resume_block'] is True:
block['resume_block'] = True
if len([child['complete'] for child in block['children'] if child['complete']]) == len(block['children']):
completable_blocks = [child for child in block['children']
if child['type'] != 'discussion']
if len([child['complete'] for child in block['children']
if child['complete']]) == len(completable_blocks):
block['complete'] = True
def mark_last_accessed(user, course_key, block):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment