remove old route for /search and fix issue where searching for empty string was failing
This commit is contained in:
9
files.py
9
files.py
@@ -505,15 +505,6 @@ def search(search_term):
|
||||
move_paths = MovePathDetails()
|
||||
return render_template("files.html", page_title='View Files', search_term=search_term, entry_data=entries, OPT=OPT, move_paths=move_paths )
|
||||
|
||||
################################################################################
|
||||
# /search -> POST version -> only used on form submit when you hit return. This
|
||||
# form just redirects to a GET of /search/<search_term> to trip route above
|
||||
################################################################################
|
||||
@app.route("/search", methods=["POST"])
|
||||
@login_required
|
||||
def search_post():
|
||||
return redirect( "/search/"+request.form['search_term'] )
|
||||
|
||||
################################################################################
|
||||
# /files/scannow -> allows us to force a check for new files
|
||||
################################################################################
|
||||
|
||||
Reference in New Issue
Block a user