Completed
Push — master ( f1bb68...f91685 )
by Alexandr
03:16
created
src/Introspection/Traits/TypeCollectorTrait.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,9 @@
 block discarded – undo
27 27
         if (!$type) {
28 28
             return;
29 29
         }
30
-        if (is_object($type) && array_key_exists($type->getName(), $this->types)) return;
30
+        if (is_object($type) && array_key_exists($type->getName(), $this->types)) {
31
+            return;
32
+        }
31 33
 
32 34
         switch ($type->getKind()) {
33 35
             case TypeMap::KIND_INTERFACE:
Please login to merge, or discard this patch.
examples/02_blog/Schema/BlogSchema.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -47,7 +47,9 @@
 block discarded – undo
47 47
                     // code for creating a new post goes here
48 48
                     // we simple use our DataProvider for now
49 49
                     $post = DataProvider::getPost(10);
50
-                    if (!empty($args['post']['title'])) $post['title'] = $args['post']['title'];
50
+                    if (!empty($args['post']['title'])) {
51
+                        $post['title'] = $args['post']['title'];
52
+                    }
51 53
                     return $post;
52 54
                 }
53 55
             ]
Please login to merge, or discard this patch.
src/Config/Schema/SchemaConfig.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@
 block discarded – undo
35 35
     }
36 36
 
37 37
     /**
38
-     * @param $query AbstractObjectType
38
+     * @param \Youshido\Tests\StarWars\Schema\QueryType $query AbstractObjectType
39 39
      *
40 40
      * @return SchemaConfig
41 41
      */
Please login to merge, or discard this patch.
src/Config/Traits/ArgumentsAwareConfigTrait.php 2 patches
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -45,6 +45,9 @@
 block discarded – undo
45 45
     {
46 46
     }
47 47
 
48
+    /**
49
+     * @param string $name
50
+     */
48 51
     public function addQuery($name, AbstractObjectType $query)
49 52
     {
50 53
         $this->getQueryType()->getConfig()->addField($name, $query);
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,9 @@
 block discarded – undo
18 18
 
19 19
     public function buildArguments()
20 20
     {
21
-        if ($this->_isArgumentsBuilt) return true;
21
+        if ($this->_isArgumentsBuilt) {
22
+            return true;
23
+        }
22 24
 
23 25
         if (!empty($this->data['args'])) {
24 26
             $this->addArguments($this->data['args']);
Please login to merge, or discard this patch.
src/Config/Traits/FieldsAwareConfigTrait.php 1 patch
Doc Comments   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
      */
94 94
 
95 95
     /**
96
-     * @param $name
96
+     * @param string $name
97 97
      *
98 98
      * @return Field
99 99
      */
@@ -125,6 +125,9 @@  discard block
 block discarded – undo
125 125
         return $this->fields;
126 126
     }
127 127
 
128
+    /**
129
+     * @param string $name
130
+     */
128 131
     public function removeField($name)
129 132
     {
130 133
         if ($this->hasField($name)) {
Please login to merge, or discard this patch.
src/Execution/Processor.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
     }
98 98
 
99 99
     /**
100
-     * @param Query|Field        $query
100
+     * @param Query        $query
101 101
      * @param AbstractObjectType $currentLevelSchema
102 102
      * @return array|bool|mixed
103 103
      */
@@ -282,7 +282,7 @@  discard block
 block discarded – undo
282 282
     }
283 283
 
284 284
     /**
285
-     * @param $query         Query|FragmentInterface
285
+     * @param Query $query         Query|FragmentInterface
286 286
      * @param $queryType     AbstractObjectType|TypeInterface|Field|AbstractType
287 287
      * @param $resolvedValue mixed
288 288
      * @param $value         array
Please login to merge, or discard this patch.
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -148,11 +148,15 @@
 block discarded – undo
148 148
     protected function collectValueForQueryWithType(Query $query, AbstractType $fieldType, $resolvedValue)
149 149
     {
150 150
         $fieldType = $this->resolveValidator->resolveTypeIfAbstract($fieldType, $resolvedValue);
151
-        if (is_null($resolvedValue)) return null;
151
+        if (is_null($resolvedValue)) {
152
+            return null;
153
+        }
152 154
 
153 155
         $value = [];
154 156
         if ($fieldType->getKind() == TypeMap::KIND_LIST) {
155
-            if (!$this->resolveValidator->hasArrayAccess($resolvedValue)) return null;
157
+            if (!$this->resolveValidator->hasArrayAccess($resolvedValue)) {
158
+                return null;
159
+            }
156 160
             foreach ($resolvedValue as $resolvedValueItem) {
157 161
                 $value[] = [];
158 162
                 $index   = count($value) - 1;
Please login to merge, or discard this patch.
src/Parser/Ast/Fragment.php 1 patch
Doc Comments   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
     }
61 61
 
62 62
     /**
63
-     * @param mixed $name
63
+     * @param string $name
64 64
      */
65 65
     public function setName($name)
66 66
     {
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
     }
77 77
 
78 78
     /**
79
-     * @param mixed $model
79
+     * @param string $model
80 80
      */
81 81
     public function setModel($model)
82 82
     {
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
     }
85 85
 
86 86
     /**
87
-     * @return Field[]|Query[]
87
+     * @return Query[]
88 88
      */
89 89
     public function getFields()
90 90
     {
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
     }
93 93
 
94 94
     /**
95
-     * @param Field[]|Query[] $fields
95
+     * @param Field[] $fields
96 96
      */
97 97
     public function setFields($fields)
98 98
     {
Please login to merge, or discard this patch.
src/Parser/Ast/Query.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -74,7 +74,7 @@
 block discarded – undo
74 74
     }
75 75
 
76 76
     /**
77
-     * @return Field[]|Query[]|FragmentInterface[]
77
+     * @return Query[]
78 78
      */
79 79
     public function getFields()
80 80
     {
Please login to merge, or discard this patch.
src/Parser/Ast/TypedFragmentReference.php 1 patch
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
     }
29 29
 
30 30
     /**
31
-     * @return Field[]|Query[]
31
+     * @return Field[]
32 32
      */
33 33
     public function getFields()
34 34
     {
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
     }
37 37
 
38 38
     /**
39
-     * @param Field[]|Query[] $fields
39
+     * @param Field[] $fields
40 40
      */
41 41
     public function setFields($fields)
42 42
     {
Please login to merge, or discard this patch.