Skip to content

Commit

Permalink
Merge pull request #298 from nextcloud/use-parameterized-query
Browse files Browse the repository at this point in the history
[stable9] Use paramterized parameter for \OC\SystemTag\SystemTagManager
  • Loading branch information
MorrisJobke authored Jul 4, 2016
2 parents 42d8ef5 + ce70ea3 commit dd8af5c
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions lib/private/systemtag/systemtagmanager.php
Original file line number Diff line number Diff line change
Expand Up @@ -124,10 +124,7 @@ public function getAllTags($visibilityFilter = null, $nameSearchPattern = null)

if (!empty($nameSearchPattern)) {
$query->andWhere(
$query->expr()->like(
'name',
$query->expr()->literal('%' . $this->connection->escapeLikeParameter($nameSearchPattern). '%')
)
$query->expr()->like('name', $query->createNamedParameter('%' . $this->connection->escapeLikeParameter($nameSearchPattern) . '%'))
);
}

Expand Down

0 comments on commit dd8af5c

Please sign in to comment.