@@ -256,7 +256,7 @@ discard block |
||
256 | 256 | |
257 | 257 | // Check query cache. |
258 | 258 | $queryCache = $this->getQueryCacheDriver(); |
259 | - if (! ($this->useQueryCache && $queryCache)) { |
|
259 | + if ( ! ($this->useQueryCache && $queryCache)) { |
|
260 | 260 | $parser = new Parser($this); |
261 | 261 | |
262 | 262 | $this->parserResult = $parser->parse(); |
@@ -394,7 +394,7 @@ discard block |
||
394 | 394 | $rsm = $this->getResultSetMapping(); |
395 | 395 | $type = null; |
396 | 396 | |
397 | - if (! isset($paramMappings[$key])) { |
|
397 | + if ( ! isset($paramMappings[$key])) { |
|
398 | 398 | throw QueryException::unknownParameter($key); |
399 | 399 | } |
400 | 400 | |
@@ -709,7 +709,7 @@ discard block |
||
709 | 709 | public function setLockMode($lockMode) |
710 | 710 | { |
711 | 711 | if (in_array($lockMode, [LockMode::NONE, LockMode::PESSIMISTIC_READ, LockMode::PESSIMISTIC_WRITE], true)) { |
712 | - if (! $this->em->getConnection()->isTransactionActive()) { |
|
712 | + if ( ! $this->em->getConnection()->isTransactionActive()) { |
|
713 | 713 | throw TransactionRequiredException::transactionRequired(); |
714 | 714 | } |
715 | 715 | } |
@@ -750,11 +750,11 @@ discard block |
||
750 | 750 | ->getName(); |
751 | 751 | |
752 | 752 | return md5( |
753 | - $this->getDQL() . serialize($this->hints) . |
|
754 | - '&platform=' . $platform . |
|
755 | - ($this->em->hasFilters() ? $this->em->getFilters()->getHash() : '') . |
|
756 | - '&firstResult=' . $this->firstResult . '&maxResult=' . $this->maxResults . |
|
757 | - '&hydrationMode=' . $this->hydrationMode . '&types=' . serialize($this->parsedTypes) . 'DOCTRINE_QUERY_CACHE_SALT' |
|
753 | + $this->getDQL().serialize($this->hints). |
|
754 | + '&platform='.$platform. |
|
755 | + ($this->em->hasFilters() ? $this->em->getFilters()->getHash() : ''). |
|
756 | + '&firstResult='.$this->firstResult.'&maxResult='.$this->maxResults. |
|
757 | + '&hydrationMode='.$this->hydrationMode.'&types='.serialize($this->parsedTypes).'DOCTRINE_QUERY_CACHE_SALT' |
|
758 | 758 | ); |
759 | 759 | } |
760 | 760 | |
@@ -763,7 +763,7 @@ discard block |
||
763 | 763 | */ |
764 | 764 | protected function getHash() |
765 | 765 | { |
766 | - return sha1(parent::getHash() . '-' . $this->firstResult . '-' . $this->maxResults); |
|
766 | + return sha1(parent::getHash().'-'.$this->firstResult.'-'.$this->maxResults); |
|
767 | 767 | } |
768 | 768 | |
769 | 769 | /** |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | $entity = new GH6443Post(); |
36 | 36 | $entity->id = 'Foo'; |
37 | 37 | |
38 | - $dql = 'SELECT p FROM ' . GH6443Post::class . ' p WHERE p = ?1'; |
|
38 | + $dql = 'SELECT p FROM '.GH6443Post::class.' p WHERE p = ?1'; |
|
39 | 39 | $query = $this->em->createQuery($dql); |
40 | 40 | |
41 | 41 | // we do not know that the internal type is a rot13, so we can not add the type parameter here |
@@ -63,7 +63,7 @@ discard block |
||
63 | 63 | $metadata = $this->em->getClassMetadata(GH6443Post::class); |
64 | 64 | $entityProxy = $this->em->getProxyFactory()->getProxy($metadata, ['id' => 'Foo']); |
65 | 65 | |
66 | - $dql = 'SELECT p FROM ' . GH6443Post::class . ' p WHERE p = ?1'; |
|
66 | + $dql = 'SELECT p FROM '.GH6443Post::class.' p WHERE p = ?1'; |
|
67 | 67 | $query = $this->em->createQuery($dql); |
68 | 68 | |
69 | 69 | // we do not know that the internal type is a rot13, so we can not add the type parameter here |