Skip to content

Commit 34201ee

Browse files
fix: removed redundant code
1 parent a964516 commit 34201ee

File tree

1 file changed

+1
-4
lines changed
  • lms/djangoapps/instructor/views

1 file changed

+1
-4
lines changed

lms/djangoapps/instructor/views/api.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1642,7 +1642,7 @@ def get(self, request, *args, **kwargs):
16421642

16431643
def _cohorts_csv_validator(file_storage, file_to_validate):
16441644
"""
1645-
Verifies that the expected columns are present in the CSV` used to add users to cohorts.
1645+
Verifies that the expected columns are present in the CSV used to add users to cohorts.
16461646
"""
16471647
with file_storage.open(file_to_validate) as f:
16481648
reader = csv.reader(f.read().decode('utf-8-sig').splitlines())
@@ -4425,9 +4425,6 @@ def get(self, request, course_id):
44254425
Response: A DRF Response object containing the serialized
44264426
course modes or an error.
44274427
"""
4428-
if not CourseOverview.objects.filter(id=course_id).exists():
4429-
return Response(status=status.HTTP_404_NOT_FOUND)
4430-
44314428
all_modes = CourseMode.objects.filter(course_id=course_id)
44324429

44334430
serializer = CourseModeSerializer(all_modes, many=True)

0 commit comments

Comments
 (0)