Fix order of parameter and escaping

Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
Joas Schilling 2017-05-12 09:33:51 +02:00
parent 65efb388e6
commit fd75c08238
No known key found for this signature in database
GPG Key ID: E166FD8976B3BAC8
1 changed files with 2 additions and 2 deletions

View File

@ -165,12 +165,12 @@ class Loader implements IMimeTypeLoader {
->where($update->expr()->neq( ->where($update->expr()->neq(
'mimetype', $update->createNamedParameter($mimetypeId) 'mimetype', $update->createNamedParameter($mimetypeId)
)) ))
->andwhere($update->expr()->neq( ->andWhere($update->expr()->neq(
'mimetype', $update->createNamedParameter($isFolderId) 'mimetype', $update->createNamedParameter($isFolderId)
)) ))
->andWhere($update->expr()->like( ->andWhere($update->expr()->like(
$update->createFunction('LOWER(' . $update->getColumnName('name') . ')'), $update->createFunction('LOWER(' . $update->getColumnName('name') . ')'),
'%' . $this->dbConnection->escapeLikeParameter($update->createNamedParameter('.' . $ext)) $update->createNamedParameter('%' . $this->dbConnection->escapeLikeParameter('.' . $ext))
)); ));
return $update->execute(); return $update->execute();
} }