Skip to content

Commit

Permalink
Merge pull request #16 from edx/dcs/course-due
Browse files Browse the repository at this point in the history
Remove course-level due dates from self-paced courses.
  • Loading branch information
Dave St.Germain authored Aug 16, 2019
2 parents 6a0e695 + 630b7f6 commit f6271a5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion edx_when/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@

from __future__ import absolute_import, unicode_literals

__version__ = '0.2'
__version__ = '0.3'

default_app_config = 'edx_when.apps.EdxWhenConfig' # pylint: disable=invalid-name
5 changes: 4 additions & 1 deletion edx_when/signals.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@ def extract_dates(sender, course_key, **kwargs): # pylint: disable=unused-argum
elif course.self_paced:
log.info('%s is self-paced. Clearing due dates', course_key)
clear_dates_for_course(course_key)
date_items = [(course.location, own_metadata(course))]
metadata = own_metadata(course)
# self-paced courses may accidentally have a course due date
metadata.pop('due', None)
date_items = [(course.location, metadata)]
else:
log.info('Publishing course dates for %s', course_key)
date_items = []
Expand Down

0 comments on commit f6271a5

Please sign in to comment.