1
0
mirror of https://github.com/owncloud/bookmarks.git synced 2025-02-18 15:54:28 +01:00

Restore mysql compat for bookmark search

This commit is contained in:
Brice Maron 2012-10-11 21:43:01 +00:00
parent f017cfdbf8
commit d1e46aef87

View File

@ -80,6 +80,9 @@ class OC_Bookmarks_Bookmarks{
$sql .= str_repeat($exist_clause, count($filters));
$params = array_merge($params, $filters);
} else {
if($CONFIG_DBTYPE == 'mysql') { //Dirty hack to allow usage of alias in where
$sql .= ' having true ';
}
foreach($filters as $filter) {
$sql .= ' AND lower(url || title || description || tags ) like ? ';
$params[] = '%' . strtolower($filter) . '%';