Completed
Pull Request — master (#4)
by Arthur
03:44
created
src/Schema/Resolve/CallableResolver.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
      */
21 21
     protected function createFunction(array $config, Field $field)
22 22
     {
23
-        return function ($node, array $arguments, ResolveInfo $info) {
23
+        return function($node, array $arguments, ResolveInfo $info) {
24 24
             $resolveConfig = $this->getResolveConfig($info);
25 25
 
26 26
             $function = $resolveConfig['function'];
Please login to merge, or discard this patch.
src/Schema/Resolve/DoctrineResolver.php 1 patch
Spacing   +2 added lines, -3 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
      */
36 36
     protected function createFunction(array $config, Field $field)
37 37
     {
38
-        return function ($node, array $arguments, ResolveInfo $info) {
38
+        return function($node, array $arguments, ResolveInfo $info) {
39 39
             $resolveConfig = $this->getResolveConfig($info);
40 40
 
41 41
             $resolveConfig = $resolveConfig + [
@@ -44,8 +44,7 @@  discard block
 block discarded – undo
44 44
 
45 45
             if (!isset($resolveConfig['method'])) {
46 46
                 $resolveConfig['method']       = $info->returnType instanceof ListOfType ?
47
-                    'findBy' :
48
-                    'findOneBy';
47
+                    'findBy' : 'findOneBy';
49 48
                 $resolveConfig['array_params'] = true;
50 49
             }
51 50
 
Please login to merge, or discard this patch.
src/Schema/Resolve/PropertyResolver.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
      */
21 21
     protected function createFunction(array $config, Field $field)
22 22
     {
23
-        return function ($node, array $arguments, ResolveInfo $info) {
23
+        return function($node, array $arguments, ResolveInfo $info) {
24 24
             $resolveConfig = $this->getResolveConfig($info);
25 25
 
26 26
             $function = $resolveConfig['function'];
Please login to merge, or discard this patch.
src/Schema/SchemaFactory.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -223,7 +223,7 @@
 block discarded – undo
223 223
 
224 224
     /**
225 225
      * @param Field[]                             $fields
226
-     * @param AbstractType|FieldContainer[]|Field $parent
226
+     * @param AbstractType $parent
227 227
      */
228 228
     private function prepareFields(array $fields, AbstractType $parent)
229 229
     {
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -170,7 +170,7 @@  discard block
 block discarded – undo
170 170
         $mapping = $interface->getChildrenClassMapping();
171 171
 
172 172
         if (!empty($mapping)) {
173
-            $resolveType = function ($object) use ($mapping) {
173
+            $resolveType = function($object) use ($mapping) {
174 174
                 foreach ($mapping as $class => $typeName) {
175 175
                     if ($object instanceof $class) {
176 176
                         return $this->typeResolver->getType($typeName);
@@ -241,7 +241,7 @@  discard block
 block discarded – undo
241 241
                 );
242 242
             }
243 243
             $field->setResolvedType(
244
-                function () use ($typeName) {
244
+                function() use ($typeName) {
245 245
                     return $this->typeResolver->resolveType($typeName);
246 246
                 }
247 247
             );
Please login to merge, or discard this patch.
tests/Mapping/Driver/YamlDriverTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@
 block discarded – undo
8 8
 {
9 9
     public function testYamlParsing()
10 10
     {
11
-        $driver = new YamlDriver(__DIR__ . '/../../data/StarWarsSchema.yml');
11
+        $driver = new YamlDriver(__DIR__.'/../../data/StarWarsSchema.yml');
12 12
 
13 13
         $schema = new SchemaContainer();
14 14
         $driver->load($schema);
Please login to merge, or discard this patch.
src/Mapping/Driver/YamlDriver.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -125,7 +125,7 @@
 block discarded – undo
125 125
             ->setResolveConfig(isset($mapping['resolve']) ? $mapping['resolve'] : []);
126 126
 
127 127
         if (!empty($mapping['interfaces'])) {
128
-            $type->setInterfaces((array) $mapping['interfaces']);
128
+            $type->setInterfaces((array)$mapping['interfaces']);
129 129
         }
130 130
 
131 131
         if (isset($mapping['values'])) {
Please login to merge, or discard this patch.
src/Mapping/Guesser/PropertyGuesser.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -42,10 +42,10 @@
 block discarded – undo
42 42
         $property  = $field->getProperty() ?: $field->getName();
43 43
         $camelName = StringHelper::camelize($property);
44 44
 
45
-        $getter    = 'get' . $camelName;
45
+        $getter    = 'get'.$camelName;
46 46
         $getsetter = lcfirst($camelName);
47
-        $isser     = 'is' . $camelName;
48
-        $hasser    = 'has' . $camelName;
47
+        $isser     = 'is'.$camelName;
48
+        $hasser    = 'has'.$camelName;
49 49
         $test      = [$getter, $getsetter, $isser, $hasser];
50 50
 
51 51
         $reflMethods = $class->getMethods(\ReflectionMethod::IS_PUBLIC);
Please login to merge, or discard this patch.