Skip to content
Snippets Groups Projects
Commit f43130f7 authored by Julian Rother's avatar Julian Rother
Browse files

Fixed return value on failure in sort_file

parent 7182a338
Branches
No related tags found
No related merge requests found
......@@ -74,7 +74,7 @@ def sort_file(filename, course=None, lectures=None):
handle = '-'.join(splitfilename[:2])
courses = query('SELECT * FROM courses WHERE handle = ?', handle)
if not courses:
return []
return [], 0
course = courses[0]
if not lectures:
lectures = query('SELECT * from lectures where course_id = ?', course['id'])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment