Added catchall

This commit is contained in:
Sebastian Speitel 2019-12-14 13:54:18 +01:00 committed by GitHub
parent 622628419b
commit c4cdf2dfd2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 5 deletions

14
app.py
View File

@ -14,11 +14,15 @@ def tu_ilmenau():
def about(): def about():
return redirect("https://github.com/clerie/walduni", code=302) return redirect("https://github.com/clerie/walduni", code=302)
@app.route('/modultafeln/<course>') @app.route('/modultafeln/<course>/')
@app.route('/modultafel/<course>') @app.route('/modultafel/<course>/')
@app.route('/modulplan/<course>') @app.route('/modulplan/<course>/')
@app.route('/module/<course>') @app.route('/module/<course>/')
def modultafeln(course): @app.route('/modultafeln/')
@app.route('/modultafel/')
@app.route('/modulplan/')
@app.route('/module/')
def modultafeln(course=""):
courseToPath = { courseToPath = {
"amw": "AngewandteMedienundKommunikationswissenschaft/Bachelor/2014", "amw": "AngewandteMedienundKommunikationswissenschaft/Bachelor/2014",