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

Made invisible chapters visible to moderators

parent 068f8f22
Branches
No related tags found
No related merge requests found
...@@ -578,7 +578,7 @@ def suggest_chapter(lectureid): ...@@ -578,7 +578,7 @@ def suggest_chapter(lectureid):
@app.route('/chapters/<int:lectureid>') @app.route('/chapters/<int:lectureid>')
def chapters(lectureid): def chapters(lectureid):
chapters = query("SELECT * FROM chapters WHERE lecture_id = ? and visible ORDER BY time DESC", lectureid) chapters = query("SELECT * FROM chapters WHERE lecture_id = ? AND (visible OR ?) ORDER BY time DESC", lectureid, ismod())
if not chapters: if not chapters:
return 'No chapters found', 404 return 'No chapters found', 404
last = None last = None
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment