Commit a9009981 by Arjun Singh

Fix anonymity leak; fix editing when rendering from main page.

parent 3bc9c749
...@@ -282,6 +282,8 @@ def single_thread(request, course_id, discussion_id, thread_id): ...@@ -282,6 +282,8 @@ def single_thread(request, course_id, discussion_id, thread_id):
thread['courseware_location'] = courseware_context['courseware_location'] thread['courseware_location'] = courseware_context['courseware_location']
thread['courseware_title'] = courseware_context['courseware_title'] thread['courseware_title'] = courseware_context['courseware_title']
threads = [utils.safe_content(thread) for thread in threads]
#recent_active_threads = cc.search_recent_active_threads( #recent_active_threads = cc.search_recent_active_threads(
# course_id, # course_id,
# recursive=False, # recursive=False,
......
...@@ -273,7 +273,7 @@ def safe_content(content): ...@@ -273,7 +273,7 @@ def safe_content(content):
'created_at', 'updated_at', 'depth', 'type', 'created_at', 'updated_at', 'depth', 'type',
'commentable_id', 'comments_count', 'at_position_list', 'commentable_id', 'comments_count', 'at_position_list',
'children', 'highlighted_title', 'highlighted_body', 'children', 'highlighted_title', 'highlighted_body',
'courseware_title', 'courseware_location' 'courseware_title', 'courseware_location', 'tags'
] ]
if content.get('anonymous') is False: if content.get('anonymous') is False:
......
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