Skip to content
This repository has been archived by the owner on Nov 8, 2018. It is now read-only.

Commit

Permalink
fix wildcard matching
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristophWurst committed Feb 8, 2016
1 parent bccb3fd commit bc29b32
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/db/collectedaddressmapper.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,13 @@ public function findMatching($userId, $query) {
$sql = 'SELECT * FROM *PREFIX*mail_collected_addresses WHERE `user_id` = ? AND `email` ILIKE ?';
$params = [
$userId,
$query
'%' . $query . '%',
];
return $this->findEntities($sql, $params);
}

public function exists($userId, $email) {
$sql = 'SELECT * FROM *PREFIX*mail_collected_addresses WHERE `user_id` = ? AND `email` = ?';
$sql = 'SELECT * FROM *PREFIX*mail_collected_addresses WHERE `user_id` = ? AND `email` ILIKE ?';
$params = [
$userId,
$email
Expand Down

0 comments on commit bc29b32

Please sign in to comment.