Fix route config

Fix fts search
Log exceptions
This commit is contained in:
2020-01-20 21:40:10 +03:00
parent b38324770b
commit 3972c6e915
3 changed files with 12 additions and 2 deletions
+1 -1
View File
@@ -99,7 +99,7 @@ def find_location_by_name(conn: sqlite3.Connection, q: str) -> List[Location]:
WHERE locations_search match :q
ORDER BY country, city, region
'''
stmt = conn.execute(sql, {'q': f'%{q}%'})
stmt = conn.execute(sql, {'q': f'{q}'})
rows = stmt.fetchall()
if not rows:
return []