List URL Route Flask List URL Route Flask flask flask

List URL Route Flask


imagePage function will be overwritten and only the last one will remain. (because def blah(..) overwrites old one).

Instead of defining multiple functions, how about coding the view as follow?

@app.route('/images/<image>')def imagePage(image):    if image not in imageIds:        abort(404)    else:        return render_template('imagePage.html')