From ca6322465d8edab9fc4d321e93015c27a0f3091c Mon Sep 17 00:00:00 2001 From: Michael Gapczynski Date: Wed, 12 Sep 2012 01:12:25 -0400 Subject: [PATCH] Treat getUsers() as case insensitive, helpful for showing proper results in the share with autocomplete --- lib/user/database.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/user/database.php b/lib/user/database.php index 76b44a2f6c..25e24fcf7e 100644 --- a/lib/user/database.php +++ b/lib/user/database.php @@ -155,7 +155,7 @@ class OC_User_Database extends OC_User_Backend { * Get a list of all users. */ public function getUsers($search = '', $limit = null, $offset = null) { - $query = OC_DB::prepare('SELECT `uid` FROM `*PREFIX*users` WHERE `uid` LIKE ?',$limit,$offset); + $query = OC_DB::prepare('SELECT `uid` FROM `*PREFIX*users` WHERE LOWER(`uid`) LIKE LOWER(?)',$limit,$offset); $result = $query->execute(array($search.'%')); $users = array(); while ($row = $result->fetchRow()) {