Passed
Pull Request — master (#8)
by Luis
28:30 queued 13:28
created
src/Parser/CodebaseDirectory.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@  discard block
 block discarded – undo
21 21
 
22 22
     public function absolutePath(): string
23 23
     {
24
-        return (string) $this->directory->getRealPath();
24
+        return (string)$this->directory->getRealPath();
25 25
     }
26 26
 
27 27
     private function setDirectory(string $path): void
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
             'The directory with the code to be scanned cannot be empty'
32 32
         );
33 33
         $directory = new SplFileInfo($path);
34
-        if (! $directory->isDir()) {
34
+        if (!$directory->isDir()) {
35 35
             throw InvalidDirectory::notFoundAt($directory);
36 36
         }
37 37
         $this->directory = $directory;
Please login to merge, or discard this patch.
src/Parser/Code/Builders/Filters/ProtectedVisibilityFilter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@
 block discarded – undo
22 22
         if ($member instanceof ClassConst
23 23
             || $member instanceof ClassMethod
24 24
             || $member instanceof Property) {
25
-            return ! $member->isProtected();
25
+            return !$member->isProtected();
26 26
         }
27 27
 
28 28
         return false;
Please login to merge, or discard this patch.
src/Parser/Code/Builders/Filters/PrivateVisibilityFilter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@
 block discarded – undo
22 22
         if ($member instanceof ClassConst
23 23
             || $member instanceof ClassMethod
24 24
             || $member instanceof Property) {
25
-            return ! $member->isPrivate();
25
+            return !$member->isPrivate();
26 26
         }
27 27
 
28 28
         return false;
Please login to merge, or discard this patch.
src/Parser/Code/Builders/TraitDefinitionBuilder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@
 block discarded – undo
32 32
     public function build(Trait_ $trait): TraitDefinition
33 33
     {
34 34
         return new TraitDefinition(
35
-            new Name((string) $trait->name),
35
+            new Name((string)$trait->name),
36 36
             $this->membersBuilder->methods($trait->getMethods()),
37 37
             $this->membersBuilder->attributes($trait->stmts),
38 38
             $this->buildTraits($trait->stmts)
Please login to merge, or discard this patch.
src/Parser/Code/Builders/ClassDefinitionBuilder.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -35,10 +35,10 @@
 block discarded – undo
35 35
     public function build(Class_ $class): ClassDefinition
36 36
     {
37 37
         return new ClassDefinition(
38
-            new ClassDefinitionName((string) $class->name),
38
+            new ClassDefinitionName((string)$class->name),
39 39
             $this->membersBuilder->methods($class->getMethods()),
40 40
             $this->membersBuilder->constants($class->stmts),
41
-            $class->extends !== null ? new ClassDefinitionName((string) end($class->extends->parts)) : null,
41
+            $class->extends !== null ? new ClassDefinitionName((string)end($class->extends->parts)) : null,
42 42
             $this->membersBuilder->attributes($class->stmts),
43 43
             $this->buildInterfaces($class->implements),
44 44
             $this->buildTraits($class->stmts)
Please login to merge, or discard this patch.
src/Parser/Code/Builders/Names/TraitNamesBuilder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
      */
20 20
     protected function buildTraits(array $nodes): array
21 21
     {
22
-        $useStatements = array_filter($nodes, static fn (Node $node): bool => $node instanceof TraitUse);
22
+        $useStatements = array_filter($nodes, static fn(Node $node): bool => $node instanceof TraitUse);
23 23
 
24 24
         if (count($useStatements) === 0) {
25 25
             return [];
Please login to merge, or discard this patch.
src/Parser/Code/Builders/Names/InterfaceNamesBuilder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,6 +18,6 @@
 block discarded – undo
18 18
      */
19 19
     protected function buildInterfaces(array $implements): array
20 20
     {
21
-        return array_map(static fn (Name $name): DefinitionName => new DefinitionName($name->getLast()), $implements);
21
+        return array_map(static fn(Name $name): DefinitionName => new DefinitionName($name->getLast()), $implements);
22 22
     }
23 23
 }
Please login to merge, or discard this patch.
src/Parser/Code/Builders/Members/FilteredAttributesBuilder.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -46,9 +46,9 @@
 block discarded – undo
46 46
      */
47 47
     public function build(array $parsedAttributes): array
48 48
     {
49
-        $attributes = array_filter($parsedAttributes, static fn ($attribute): bool => $attribute instanceof Property);
49
+        $attributes = array_filter($parsedAttributes, static fn($attribute): bool => $attribute instanceof Property);
50 50
 
51
-        return array_map(function (Property $attribute): Attribute {
51
+        return array_map(function(Property $attribute): Attribute {
52 52
             $variable = new Variable(
53 53
                 "\${$attribute->props[0]->name}",
54 54
                 $this->typeBuilder->fromAttributeType($attribute->type, $attribute->getDocComment())
Please login to merge, or discard this patch.
src/Parser/Code/Builders/Members/FilteredMethodsBuilder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@
 block discarded – undo
48 48
     public function build(array $methods): array
49 49
     {
50 50
         return array_map(
51
-            fn (ClassMethod $method): Method => $this->buildMethod($method),
51
+            fn(ClassMethod $method): Method => $this->buildMethod($method),
52 52
             $this->visibilityFilters->apply($methods)
53 53
         );
54 54
     }
Please login to merge, or discard this patch.