Completed
Pull Request — 2.5 (#7181)
by
unknown
11:02
created
lib/Doctrine/ORM/Mapping/DefaultEntityListenerResolver.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@
 block discarded – undo
67 67
     public function resolve($className)
68 68
     {
69 69
         if (isset($this->instances[$className = trim($className, '\\')])) {
70
-           return $this->instances[$className];
70
+            return $this->instances[$className];
71 71
         }
72 72
 
73 73
         return $this->instances[$className] = new $className();
Please login to merge, or discard this patch.
lib/Doctrine/ORM/AbstractQuery.php 4 patches
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -22,11 +22,9 @@
 block discarded – undo
22 22
 use Doctrine\Common\Util\ClassUtils;
23 23
 use Doctrine\Common\Collections\Collection;
24 24
 use Doctrine\Common\Collections\ArrayCollection;
25
-
26 25
 use Doctrine\ORM\Query\Parameter;
27 26
 use Doctrine\ORM\Cache\QueryCacheKey;
28 27
 use Doctrine\DBAL\Cache\QueryCacheProfile;
29
-
30 28
 use Doctrine\ORM\Cache;
31 29
 use Doctrine\ORM\Query\ResultSetMapping;
32 30
 
Please login to merge, or discard this patch.
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -213,10 +213,10 @@
 block discarded – undo
213 213
     }
214 214
 
215 215
     /**
216
-    * Obtain the name of the second level query cache region in which query results will be stored
217
-    *
218
-    * @return The cache region name; NULL indicates the default region.
219
-    */
216
+     * Obtain the name of the second level query cache region in which query results will be stored
217
+     *
218
+     * @return The cache region name; NULL indicates the default region.
219
+     */
220 220
     public function getCacheRegion()
221 221
     {
222 222
         return $this->cacheRegion;
Please login to merge, or discard this patch.
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
     /**
216 216
     * Obtain the name of the second level query cache region in which query results will be stored
217 217
     *
218
-    * @return The cache region name; NULL indicates the default region.
218
+    * @return string|null cache region name; NULL indicates the default region.
219 219
     */
220 220
     public function getCacheRegion()
221 221
     {
@@ -1039,7 +1039,7 @@  discard block
 block discarded – undo
1039 1039
      * Will return the configured id if it exists otherwise a hash will be
1040 1040
      * automatically generated for you.
1041 1041
      *
1042
-     * @return array ($key, $hash)
1042
+     * @return string[] ($key, $hash)
1043 1043
      */
1044 1044
     protected function getHydrationCacheId()
1045 1045
     {
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -325,7 +325,7 @@  discard block
 block discarded – undo
325 325
     public function getParameter($key)
326 326
     {
327 327
         $filteredParameters = $this->parameters->filter(
328
-            function (Query\Parameter $parameter) use ($key) {
328
+            function(Query\Parameter $parameter) use ($key) {
329 329
                 $parameterName = $parameter->getName();
330 330
 
331 331
                 return $key === $parameterName || (string) $key === (string) $parameterName;
@@ -463,7 +463,7 @@  discard block
 block discarded – undo
463 463
      */
464 464
     private function translateNamespaces(Query\ResultSetMapping $rsm)
465 465
     {
466
-        $translate = function ($alias) {
466
+        $translate = function($alias) {
467 467
             return $this->_em->getClassMetadata($alias)->getName();
468 468
         };
469 469
 
@@ -994,7 +994,7 @@  discard block
 block discarded – undo
994 994
             $this->getTimestampKey()
995 995
         );
996 996
 
997
-        $result     = $queryCache->get($queryKey, $rsm, $this->_hints);
997
+        $result = $queryCache->get($queryKey, $rsm, $this->_hints);
998 998
 
999 999
         if ($result !== null) {
1000 1000
             if ($this->cacheLogger) {
@@ -1130,6 +1130,6 @@  discard block
 block discarded – undo
1130 1130
 
1131 1131
         ksort($hints);
1132 1132
 
1133
-        return sha1($query . '-' . serialize($params) . '-' . serialize($hints));
1133
+        return sha1($query.'-'.serialize($params).'-'.serialize($hints));
1134 1134
     }
1135 1135
 }
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Query/Expr/Literal.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@
 block discarded – undo
33 33
     /**
34 34
      * @var string
35 35
      */
36
-    protected $preSeparator  = '';
36
+    protected $preSeparator = '';
37 37
 
38 38
     /**
39 39
      * @var string
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Cache/CacheConfiguration.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
      */
74 74
     public function getCacheLogger()
75 75
     {
76
-         return $this->cacheLogger;
76
+            return $this->cacheLogger;
77 77
     }
78 78
 
79 79
     /**
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
             );
116 116
         }
117 117
 
118
-         return $this->queryValidator;
118
+            return $this->queryValidator;
119 119
     }
120 120
 
121 121
     /**
Please login to merge, or discard this patch.
ORM/Cache/Persister/Entity/NonStrictReadWriteCachedEntityPersister.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,6 @@
 block discarded – undo
20 20
 
21 21
 namespace Doctrine\ORM\Cache\Persister\Entity;
22 22
 
23
-use Doctrine\Common\Util\ClassUtils;
24 23
 use Doctrine\ORM\Cache\EntityCacheKey;
25 24
 
26 25
 /**
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Query/AST/Functions/TrimFunction.php 1 patch
Doc Comments   -1 removed lines patch added patch discarded remove patch
@@ -105,7 +105,6 @@
 block discarded – undo
105 105
     }
106 106
 
107 107
     /**
108
-     * @param \Doctrine\ORM\Query\Parser $parser
109 108
      *
110 109
      * @return integer
111 110
      */
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Query/TreeWalkerChainIterator.php 1 patch
Doc Comments   +4 added lines patch added patch discarded remove patch
@@ -41,6 +41,10 @@
 block discarded – undo
41 41
      */
42 42
     private $parserResult;
43 43
 
44
+    /**
45
+     * @param \Doctrine\ORM\AbstractQuery $query
46
+     * @param ParserResult $parserResult
47
+     */
44 48
     public function __construct(TreeWalkerChain $treeWalkerChain, $query, $parserResult)
45 49
     {
46 50
         $this->treeWalkerChain = $treeWalkerChain;
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Tools/AttachEntityListenersListener.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
      * @param string $entityClass           The entity to attach the listener.
42 42
      * @param string $listenerClass         The listener class.
43 43
      * @param string $eventName             The entity lifecycle event.
44
-     * @param string $listenerCallback|null The listener callback method or NULL to use $eventName.
44
+     * @param string $listenerCallback The listener callback method or NULL to use $eventName.
45 45
      *
46 46
      * @return void
47 47
      */
Please login to merge, or discard this patch.
lib/Doctrine/ORM/Event/ListenersInvoker.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -97,13 +97,13 @@  discard block
 block discarded – undo
97 97
      */
98 98
     public function invoke(ClassMetadata $metadata, $eventName, $entity, EventArgs $event, $invoke)
99 99
     {
100
-        if($invoke & self::INVOKE_CALLBACKS) {
100
+        if ($invoke & self::INVOKE_CALLBACKS) {
101 101
             foreach ($metadata->lifecycleCallbacks[$eventName] as $callback) {
102 102
                 $entity->$callback($event);
103 103
             }
104 104
         }
105 105
 
106
-        if($invoke & self::INVOKE_LISTENERS) {
106
+        if ($invoke & self::INVOKE_LISTENERS) {
107 107
             foreach ($metadata->entityListeners[$eventName] as $listener) {
108 108
                 $class      = $listener['class'];
109 109
                 $method     = $listener['method'];
@@ -113,7 +113,7 @@  discard block
 block discarded – undo
113 113
             }
114 114
         }
115 115
 
116
-        if($invoke & self::INVOKE_MANAGER) {
116
+        if ($invoke & self::INVOKE_MANAGER) {
117 117
             $this->eventManager->dispatchEvent($eventName, $event);
118 118
         }
119 119
     }
Please login to merge, or discard this patch.