Completed
Push — master ( 93dd0d...2e24e7 )
by Tim
02:24
created
Classes/Utility/ReflectionUtility.php 2 patches
Doc Comments   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
      * @param string $className
133 133
      * @param string $tag
134 134
      *
135
-     * @return string|bool
135
+     * @return false|string
136 136
      */
137 137
     public static function getFirstTagValue(string $className, string $tag)
138 138
     {
@@ -187,7 +187,7 @@  discard block
 block discarded – undo
187 187
      * Get the tag configuration from this method and respect multiple line and space configuration.
188 188
      *
189 189
      * @param string $className
190
-     * @param array                            $tagNames
190
+     * @param string[]                            $tagNames
191 191
      *
192 192
      * @return array
193 193
      */
@@ -217,8 +217,8 @@  discard block
 block discarded – undo
217 217
     /**
218 218
      * Get the tag configuration from this method and respect multiple line and space configuration.
219 219
      *
220
-     * @param MethodReflection|ClassReflection $reflectionObject
221
-     * @param array                            $tagNames
220
+     * @param string[]                            $tagNames
221
+     * @param string $className
222 222
      *
223 223
      * @return array
224 224
      */
@@ -246,8 +246,8 @@  discard block
 block discarded – undo
246 246
     /**
247 247
      * Get the tag configuration from this method and respect multiple line and space configuration.
248 248
      *
249
-     * @param MethodReflection|ClassReflection $reflectionObject
250
-     * @param array                            $tagNames
249
+     * @param string[]                            $tagNames
250
+     * @param string $className
251 251
      *
252 252
      * @return array
253 253
      */
Please login to merge, or discard this patch.
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
      */
43 43
     public static function isInstantiable($className):bool
44 44
     {
45
-        if(self::is9orHigher()) {
45
+        if (self::is9orHigher()) {
46 46
             $reflectionClass = new \ReflectionClass($className);
47 47
             return (bool)$reflectionClass->isInstantiable();
48 48
         }
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
      */
61 61
     public static function getParentClassName($className)
62 62
     {
63
-        if(self::is9orHigher()) {
63
+        if (self::is9orHigher()) {
64 64
             $reflectionClass = new \ReflectionClass($className);
65 65
             return $reflectionClass->getParentClass()->getName();
66 66
         }
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
         $return = [];
106 106
         foreach ($properties as $property) {
107 107
             $config = self::getTagConfigurationForProperty($className, $property, [$tag]);
108
-            if(!empty($config[$tag])) {
108
+            if (!empty($config[$tag])) {
109 109
                 $return[] = $property;
110 110
             }
111 111
         }
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
      */
137 137
     public static function getFirstTagValue(string $className, string $tag)
138 138
     {
139
-        if(self::is9orHigher()) {
139
+        if (self::is9orHigher()) {
140 140
             $reflectionService = GeneralUtility::makeInstance(ReflectionService::class);
141 141
             $values = $reflectionService->getClassTagValues($className, $tag);
142 142
         } else {
@@ -148,7 +148,7 @@  discard block
 block discarded – undo
148 148
         }
149 149
 
150 150
         if (\is_array($values)) {
151
-            return \trim((string) $values[0]);
151
+            return \trim((string)$values[0]);
152 152
         }
153 153
 
154 154
         return false;
@@ -325,10 +325,10 @@  discard block
 block discarded – undo
325 325
     public static function getDeclaringProperties($className)
326 326
     {
327 327
         $classReflection = new \ReflectionClass($className);
328
-        $own = array_filter($classReflection->getProperties(), function ($property) use ($className) {
328
+        $own = array_filter($classReflection->getProperties(), function($property) use ($className) {
329 329
             return $property->class == $className;
330 330
         });
331
-        return array_map(function($item){
331
+        return array_map(function($item) {
332 332
             return $item->name;
333 333
         }, $own);
334 334
     }
Please login to merge, or discard this patch.
Classes/Service/SmartObjectInformationService.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -204,9 +204,9 @@  discard block
 block discarded – undo
204 204
      */
205 205
     protected function useTableNameFileBase()
206 206
     {
207
-        $configuration = \unserialize((string) $GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf']['autoloader']);
207
+        $configuration = \unserialize((string)$GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf']['autoloader']);
208 208
 
209
-        return isset($configuration['enableLanguageFileOnTableBase']) ? (bool) $configuration['enableLanguageFileOnTableBase'] : false;
209
+        return isset($configuration['enableLanguageFileOnTableBase']) ? (bool)$configuration['enableLanguageFileOnTableBase'] : false;
210 210
     }
211 211
 
212 212
     /**
@@ -276,9 +276,9 @@  discard block
 block discarded – undo
276 276
             $fields[] = [
277 277
                 'property' => $propertyName,
278 278
                 'name' => $nameMapperService->getDatabaseFieldName($tableName, $propertyName),
279
-                'db' => \trim((string) $configuration['db'][0]),
280
-                'var' => \trim((string) $var),
281
-                'rte' => (bool) !empty($configuration['enableRichText'][0]),
279
+                'db' => \trim((string)$configuration['db'][0]),
280
+                'var' => \trim((string)$var),
281
+                'rte' => (bool)!empty($configuration['enableRichText'][0]),
282 282
             ];
283 283
         }
284 284
 
@@ -341,7 +341,7 @@  discard block
 block discarded – undo
341 341
         $classReflection = ReflectionUtility::createReflectionClass($modelClassName);
342 342
         if ($classReflection->isTaggedWith('key')) {
343 343
             $additionalKeys = $classReflection->getTagValues('key');
344
-            \array_walk($additionalKeys, function (&$item) {
344
+            \array_walk($additionalKeys, function(&$item) {
345 345
                 $item = 'KEY ' . $item;
346 346
             });
347 347
             $fields = \array_merge($fields, $additionalKeys);
Please login to merge, or discard this patch.
Classes/Mapper/ModelMapper.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -29,8 +29,8 @@
 block discarded – undo
29 29
         }
30 30
         try {
31 31
             $reflection = new \ReflectionClass($type);
32
-            while($reflection = $reflection->getParentClass()) {
33
-                if($reflection->getName() === AbstractEntity::class) {
32
+            while ($reflection = $reflection->getParentClass()) {
33
+                if ($reflection->getName() === AbstractEntity::class) {
34 34
                     return true;
35 35
                 }
36 36
             }
Please login to merge, or discard this patch.