@@ -162,8 +162,8 @@ |
||
162 | 162 | if ($type instanceof Types\Compound) { |
163 | 163 | |
164 | 164 | return Psi::it($this->getCompoundChildren($type)) |
165 | - ->filter(new IsInstanceOf(Types\Null_::class)) |
|
166 | - ->count() > 0; |
|
165 | + ->filter(new IsInstanceOf(Types\Null_::class)) |
|
166 | + ->count() > 0; |
|
167 | 167 | } |
168 | 168 | |
169 | 169 | return false; |
@@ -40,8 +40,8 @@ |
||
40 | 40 | Visibility::fromReflection($property), |
41 | 41 | $this->isNullable($varTag->getType()), |
42 | 42 | new DomainModel\Docs\Doc( |
43 | - (string)$docBlock->getSummary(), |
|
44 | - (string)$docBlock->getDescription() |
|
43 | + (string) $docBlock->getSummary(), |
|
44 | + (string) $docBlock->getDescription() |
|
45 | 45 | ) |
46 | 46 | ); |
47 | 47 | } |
@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | |
57 | 57 | /** @noinspection ExceptionsAnnotatingAndHandlingInspection */ |
58 | 58 | AnnotationRegistry::registerLoader( |
59 | - function ($class) { |
|
59 | + function($class) { |
|
60 | 60 | return class_exists($class) || interface_exists($class) || trait_exists($class); |
61 | 61 | } |
62 | 62 | ); |
@@ -280,21 +280,21 @@ discard block |
||
280 | 280 | $properties = Psi::it($class->getProperties()) |
281 | 281 | // is it a non-static property |
282 | 282 | ->filter( |
283 | - function (\ReflectionProperty $p) { return $p->isStatic() === false; } |
|
283 | + function(\ReflectionProperty $p) { return $p->isStatic() === false; } |
|
284 | 284 | ) |
285 | 285 | // is the property declared by the Class or one of the Traits it uses ? |
286 | 286 | ->filter( |
287 | - function (\ReflectionProperty $p) use ($class) { |
|
287 | + function(\ReflectionProperty $p) use ($class) { |
|
288 | 288 | return $this->getDeclaringClassInInheritanceChain($class, $p) === $class; |
289 | 289 | } |
290 | 290 | ) |
291 | 291 | // filter properties |
292 | 292 | ->filter( |
293 | - function (\ReflectionProperty $p) { return $this->propertyFilter->filterProperty($p); } |
|
293 | + function(\ReflectionProperty $p) { return $this->propertyFilter->filterProperty($p); } |
|
294 | 294 | ) |
295 | 295 | // map properties |
296 | 296 | ->map( |
297 | - function (\ReflectionProperty $p) { return $this->buildProperty($p); } |
|
297 | + function(\ReflectionProperty $p) { return $this->buildProperty($p); } |
|
298 | 298 | ) |
299 | 299 | // collect |
300 | 300 | ->toArray(); |
@@ -348,7 +348,7 @@ discard block |
||
348 | 348 | private function getRealDeclaringClass(\ReflectionClass $class, \ReflectionProperty $prop) |
349 | 349 | { |
350 | 350 | $declaringTrait = Psi::it($class->getTraits()) |
351 | - ->filter(function (\ReflectionClass $r) use ($prop) { return $r->hasProperty($prop->getName()); }) |
|
351 | + ->filter(function(\ReflectionClass $r) use ($prop) { return $r->hasProperty($prop->getName()); }) |
|
352 | 352 | ->getFirst(null); |
353 | 353 | |
354 | 354 | // We found it on the traits. No we need to recurse on traits to find exactly the one that was defining it |