aboutsummaryrefslogtreecommitdiff
path: root/api/social
diff options
context:
space:
mode:
authorlonkaars <l.leblansch@gmail.com>2021-03-14 13:30:59 +0100
committerlonkaars <l.leblansch@gmail.com>2021-03-14 13:30:59 +0100
commita87831846d1f82c0da851e55c6599f6f5a24791f (patch)
tree3e34ede72623a5bfc7d29a2c30c7aa007740ae05 /api/social
parent5b8b222cfea6e00e452bcedbd88881380281e199 (diff)
use lower() for register, search and login
Diffstat (limited to 'api/social')
-rw-r--r--api/social/search.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/api/social/search.py b/api/social/search.py
index a9bb385..ccc62e5 100644
--- a/api/social/search.py
+++ b/api/social/search.py
@@ -13,7 +13,7 @@ def index():
if not query: return "", 400
if len(query) < 3: return "", 403
- results = cursor.execute("select user_id from users where levenshtein(username, ?, 3)", [query]).fetchmany(20);
+ results = cursor.execute("select user_id from users where levenshtein(lower(username), lower(?), 3)", [query]).fetchmany(20);
formatted = { "results": [] }