1
0
Fork 0
mirror of https://github.com/Findus23/cr-search.git synced 2024-09-19 15:23:44 +02:00

allow longer search terms

This commit is contained in:
Lukas Winkler 2021-07-15 22:24:56 +02:00
parent 10a46f5b43
commit a793ace78c
Signed by: lukas
GPG key ID: 54DE4D798D244853

View file

@ -69,7 +69,7 @@ def api_question():
series = request.args.get('series')
if not query or not until or not series:
return "no suggest query", 400
if len(query) > 50:
if len(query) > 500:
return "too long query", 400
cache_key = f"suggest_{until}_{series}_{query}"
if len(query) < 3:
@ -94,7 +94,7 @@ def api_search():
exact = False # don't allow exact searches
if not query or not until or not series:
return "no search query", 400
if len(query) > 50:
if len(query) > 500:
return "too long query", 400
if exact: