Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions cms/djangoapps/contentstore/views/tabs.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@ def initialize_course_tabs(course):

# This logic is repeated in xmodule/modulestore/tests/factories.py
# so if you change anything here, you need to also change it there.
course.tabs = [{"type": "courseware"},
{"type": "course_info", "name": "Course Info"},
{"type": "discussion", "name": "Discussion"},
{"type": "wiki", "name": "Wiki"},
{"type": "progress", "name": "Progress"}]
course.tabs = [{"type": "courseware", "name": _("Courseware")},
{"type": "course_info", "name": _("Course Info")},
{"type": "discussion", "name": _("Discussion")},
{"type": "wiki", "name": _("Wiki")},
{"type": "progress", "name": _("Progress")}]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With respect to breaking long lines, please see https://github.com/edx/edx-platform/wiki/Python-Guidelines

It's more readable to be like

course.tabs = [
    {"type": "courseware"},
    ....
    {"type": "progress", "name": _("Progress")},
]

The trailing comma I put at the end of "progress" line is OK - it's Python! 😄


modulestore('direct').update_metadata(course.location.url(), own_metadata(course))

Expand Down