aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle/Repository/EntryRepository.php
diff options
context:
space:
mode:
authorJeremy Benoist <jeremy.benoist@gmail.com>2016-01-15 15:28:22 +0100
committerJeremy Benoist <jeremy.benoist@gmail.com>2016-01-15 15:28:32 +0100
commit78833672469f7beb0c4a195aa0a76f7ca4133057 (patch)
tree87e295afbfc22e94262f3c498ce758a1101c939e /src/Wallabag/CoreBundle/Repository/EntryRepository.php
parent790573d45899504bdecd2573c8f64018e23b139e (diff)
downloadwallabag-78833672469f7beb0c4a195aa0a76f7ca4133057.tar.gz
wallabag-78833672469f7beb0c4a195aa0a76f7ca4133057.tar.zst
wallabag-78833672469f7beb0c4a195aa0a76f7ca4133057.zip
Fix `findOneByUrl` side effect in tests
Fix #1566
Diffstat (limited to 'src/Wallabag/CoreBundle/Repository/EntryRepository.php')
-rw-r--r--src/Wallabag/CoreBundle/Repository/EntryRepository.php3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/Wallabag/CoreBundle/Repository/EntryRepository.php b/src/Wallabag/CoreBundle/Repository/EntryRepository.php
index a16be9e0..82eb9474 100644
--- a/src/Wallabag/CoreBundle/Repository/EntryRepository.php
+++ b/src/Wallabag/CoreBundle/Repository/EntryRepository.php
@@ -235,10 +235,9 @@ class EntryRepository extends EntityRepository
235 * 235 *
236 * @return array|bool 236 * @return array|bool
237 */ 237 */
238 public function existByUrlAndUserId($url, $userId) 238 public function findByUrlAndUserId($url, $userId)
239 { 239 {
240 $res = $this->createQueryBuilder('e') 240 $res = $this->createQueryBuilder('e')
241 ->select('e.id, e.createdAt')
242 ->where('e.url = :url')->setParameter('url', $url) 241 ->where('e.url = :url')->setParameter('url', $url)
243 ->andWhere('e.user = :user_id')->setParameter('user_id', $userId) 242 ->andWhere('e.user = :user_id')->setParameter('user_id', $userId)
244 ->getQuery() 243 ->getQuery()