From 4ac1a7411713e4850fcd52679ec9f575ebac1c63 Mon Sep 17 00:00:00 2001 From: Chris Dodge Date: Sun, 14 Oct 2012 21:29:00 -0400 Subject: [PATCH] when calling jump_to when location= then Position is being computed as None. The redirect then yields a 404. Force Position to be 0 when Position=None --- lms/djangoapps/courseware/views.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lms/djangoapps/courseware/views.py b/lms/djangoapps/courseware/views.py index b8c8f5e912..e12c5bf93d 100644 --- a/lms/djangoapps/courseware/views.py +++ b/lms/djangoapps/courseware/views.py @@ -325,6 +325,11 @@ def jump_to(request, course_id, location): except NoPathToItem: raise Http404("This location is not in any class: {0}".format(location)) + if position is None: + return redirect('courseware_section', course_id=course_id, + chapter=chapter, + section=section) + # Rely on index to do all error handling and access control. return redirect('courseware_position', course_id=course_id,