Completed
Push — master ( 4fa5e5...5bda77 )
by Aleh
06:14 queued 02:58
created
src/Padawan/Parser/Transformer/ClassAssignmentTransformer.php 1 patch
Doc Comments   +5 added lines patch added patch discarded remove patch
@@ -16,6 +16,11 @@
 block discarded – undo
16 16
     {
17 17
         $this->typeResolver = $typeResolver;
18 18
     }
19
+
20
+    /**
21
+     * @param \Padawan\Domain\Core\Completion\Scope\MethodScope $scope
22
+     * @param \Padawan\Domain\Core\Index $index
23
+     */
19 24
     public function transform(Assign $node, ClassData $class, $scope, $index)
20 25
     {
21 26
         $fetch = $node->var;
Please login to merge, or discard this patch.
src/Padawan/Parser/Walker/ScopeWalker.php 2 patches
Doc Comments   +4 added lines patch added patch discarded remove patch
@@ -88,6 +88,10 @@
 block discarded – undo
88 88
         }
89 89
         return $line >= $startLine;
90 90
     }
91
+
92
+    /**
93
+     * @param Node $node
94
+     */
91 95
     public function getNodeLines($node)
92 96
     {
93 97
         $startLine = $endLine = -1;
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,6 @@
 block discarded – undo
12 12
 use Padawan\Domain\Core\Node\Variable;
13 13
 use Padawan\Domain\Core\Completion\Scope;
14 14
 use Padawan\Domain\Core\Completion\Scope\FileScope;
15
-use Padawan\Domain\Core\Completion\Scope\FunctionScope;
16 15
 use Padawan\Domain\Core\Completion\Scope\MethodScope;
17 16
 use Padawan\Domain\Core\Completion\Scope\ClassScope;
18 17
 use Padawan\Domain\Core\Completion\Scope\ClosureScope;
Please login to merge, or discard this patch.
src/Padawan/Domain/Core/FQCN.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -7,8 +7,7 @@
 block discarded – undo
7 7
     public function __get($key) {
8 8
         if ($key === "className") {
9 9
             return $this->getClassName();
10
-        }
11
-        elseif ($key === "namespace") {
10
+        } elseif ($key === "namespace") {
12 11
             return $this->getNamespace();
13 12
         }
14 13
     }
Please login to merge, or discard this patch.
src/Padawan/Domain/Core/FQN.php 1 patch
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -8,15 +8,12 @@
 block discarded – undo
8 8
         if ($namespace) {
9 9
             if ($namespace instanceof FQN) {
10 10
                 $this->parts = $namespace->getParts();
11
-            }
12
-            elseif (!is_array($namespace)) {
11
+            } elseif (!is_array($namespace)) {
13 12
                 $this->parts = explode("\\", $namespace);
14
-            }
15
-            else {
13
+            } else {
16 14
                 $this->parts = $namespace;
17 15
             }
18
-        }
19
-        else {
16
+        } else {
20 17
             $this->parts = [];
21 18
         }
22 19
     }
Please login to merge, or discard this patch.
src/Padawan/Domain/Core/Node/ClassProperty.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@
 block discarded – undo
45 45
     /**
46 46
      * @param integer $modifier
47 47
      */
48
-    public function setModifier($modifier){
48
+    public function setModifier($modifier) {
49 49
         $this->modifier = $modifier;
50 50
     }
51 51
 }
Please login to merge, or discard this patch.
src/Padawan/Parser/ClassParser.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -52,15 +52,13 @@
 block discarded – undo
52 52
         foreach ($node->stmts AS $child) {
53 53
             if ($child instanceof ClassMethod) {
54 54
                 $classData->addMethod($this->parseMethod($child));
55
-            }
56
-            elseif ($child instanceof Property) {
55
+            } elseif ($child instanceof Property) {
57 56
                 foreach ($child->props AS $prop) {
58 57
                     $classData->addProp(
59 58
                         $this->parseProperty($prop, $child->type, $child->getAttribute('comments'))
60 59
                     );
61 60
                 }
62
-            }
63
-            elseif ($child instanceof ClassConst) {
61
+            } elseif ($child instanceof ClassConst) {
64 62
                 foreach ($child->consts AS $const) {
65 63
                     $classData->addConst($const->name);
66 64
                 }
Please login to merge, or discard this patch.
src/Padawan/Parser/ErrorFreePhpParser.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,8 +8,7 @@
 block discarded – undo
8 8
     public function parse($content) {
9 9
         try {
10 10
             return parent::parse($content);
11
-        }
12
-        catch (\Exception $e) {
11
+        } catch (\Exception $e) {
13 12
             return $this->semValue;
14 13
         }
15 14
     }
Please login to merge, or discard this patch.
src/Padawan/Parser/ParamParser.php 1 patch
Braces   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -12,9 +12,9 @@
 block discarded – undo
12 12
     }
13 13
     public function parse(Param $node) {
14 14
         $param = new MethodParam($node->name);
15
-        if ($node->type instanceof Name)
16
-            $param->setFQCN($this->useParser->getFQCN($node->type));
17
-        else {
15
+        if ($node->type instanceof Name) {
16
+                    $param->setFQCN($this->useParser->getFQCN($node->type));
17
+        } else {
18 18
             $param->setType($node->type);
19 19
         }
20 20
         return $param;
Please login to merge, or discard this patch.
src/Padawan/Parser/CommentParser.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,8 +8,7 @@
 block discarded – undo
8 8
     public function parse($content) {
9 9
         try {
10 10
             return parent::parse($content);
11
-        }
12
-        catch (\Exception $e) {
11
+        } catch (\Exception $e) {
13 12
             return $this->semValue;
14 13
         }
15 14
     }
Please login to merge, or discard this patch.