fix(routing): handle slashes in search queries

Changed query parameter type to 'path' in search endpoint to ensure that slashes in search queries are correctly handled. This resolves issues with queries containing slashes not being processed properly.

Fixes #37.
This commit is contained in:
Kumi 2024-08-30 17:05:26 +02:00
parent 9b62a5704b
commit 1bbb37be7e
Signed by: kumi
GPG key ID: ECBCC9082395383F

View file

@ -406,7 +406,7 @@ def wiki_article(
) )
@app.route("/<project>/<lang>/search/<query>") @app.route("/<project>/<lang>/search/<path:query>")
def search_results( def search_results(
project: str, lang: str, query: str project: str, lang: str, query: str
) -> Union[Text, Tuple[Text, int]]: ) -> Union[Text, Tuple[Text, int]]: