@@ -42,7 +42,7 @@ discard block |
||
42 | 42 | foreach ($typeFields as $fieldName => $field) { |
43 | 43 | $className = get_class($field); |
44 | 44 | // We can generate queries for all but Object types, as Object types are relations |
45 | - if (! in_array($className, self::$supportedGraphQLTypes)) { |
|
45 | + if (!in_array($className, self::$supportedGraphQLTypes)) { |
|
46 | 46 | continue; |
47 | 47 | } |
48 | 48 | |
@@ -97,6 +97,6 @@ discard block |
||
97 | 97 | } |
98 | 98 | |
99 | 99 | |
100 | - return $allQuery ."\r\n". $paginatedQuery; |
|
100 | + return $allQuery . "\r\n" . $paginatedQuery; |
|
101 | 101 | } |
102 | 102 | } |
@@ -21,7 +21,7 @@ |
||
21 | 21 | foreach ($typeFields as $fieldName => $field) { |
22 | 22 | $config = $field->config; |
23 | 23 | |
24 | - $required = isset($config['generator-required']) ? ($config['generator-required'] ? '!' : '') : ''; |
|
24 | + $required = isset($config['generator-required']) ? ($config['generator-required'] ? '!' : '') : ''; |
|
25 | 25 | $className = get_class($field); |
26 | 26 | if ($className !== ObjectType::class) { |
27 | 27 | continue; |
@@ -46,7 +46,7 @@ |
||
46 | 46 | $arguments = []; |
47 | 47 | foreach ($typeFields as $fieldName => $field) { |
48 | 48 | $className = get_class($field); |
49 | - if (! in_array($className, self::$supportedGraphQLTypes) || in_array($fieldName, self::$ignoredColumns)) { |
|
49 | + if (!in_array($className, self::$supportedGraphQLTypes) || in_array($fieldName, self::$ignoredColumns)) { |
|
50 | 50 | continue; |
51 | 51 | }; |
52 | 52 |
@@ -24,7 +24,7 @@ |
||
24 | 24 | */ |
25 | 25 | public function isNotEmpty(): bool |
26 | 26 | { |
27 | - return (! empty($this->getMutation()) && ! empty($this->getInputType())); |
|
27 | + return (!empty($this->getMutation()) && !empty($this->getInputType())); |
|
28 | 28 | } |
29 | 29 | |
30 | 30 | /** |
@@ -118,7 +118,7 @@ |
||
118 | 118 | */ |
119 | 119 | private function indentRows(array $cleared): array |
120 | 120 | { |
121 | - return array_map(function ($row) { |
|
121 | + return array_map(function($row) { |
|
122 | 122 | return ' ' . $row; |
123 | 123 | }, $cleared); |
124 | 124 | } |
@@ -24,7 +24,7 @@ |
||
24 | 24 | */ |
25 | 25 | public function isNotEmpty(): bool |
26 | 26 | { |
27 | - return (! empty($this->getQueries()) && ! empty($this->getInputType())); |
|
27 | + return (!empty($this->getQueries()) && !empty($this->getInputType())); |
|
28 | 28 | } |
29 | 29 | |
30 | 30 | /** |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | */ |
30 | 30 | public function parseValue($value) |
31 | 31 | { |
32 | - if (! \preg_match(self::PATTERN, $value)) { |
|
32 | + if (!\preg_match(self::PATTERN, $value)) { |
|
33 | 33 | throw new Error(sprintf('Input error: Expected valid postal code with pattern [1234aa], got: [%s]', $value)); |
34 | 34 | } |
35 | 35 | |
@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | */ |
42 | 42 | public function parseLiteral($valueNode, array $variables = null) |
43 | 43 | { |
44 | - if (! $valueNode instanceof StringValueNode) { |
|
44 | + if (!$valueNode instanceof StringValueNode) { |
|
45 | 45 | throw new Error('Query error: Can only parse strings got: ' . $valueNode->kind, [$valueNode]); |
46 | 46 | } |
47 | 47 |
@@ -9,7 +9,7 @@ discard block |
||
9 | 9 | { |
10 | 10 | const CONFIG_PATH = __DIR__ . '/../config/lighthouse-utils.php'; |
11 | 11 | const MIGRATION_PATH = __DIR__ . '/../database/migrations/create_graphql_schema_table.php.stub'; |
12 | - const DIRECTIVE_PATH = __DIR__.'/Directives'; |
|
12 | + const DIRECTIVE_PATH = __DIR__ . '/Directives'; |
|
13 | 13 | const DIRECTIVE_NAMESPACE = 'DeInternetJongens\\LighthouseUtils\\Directives'; |
14 | 14 | |
15 | 15 | |
@@ -30,10 +30,10 @@ discard block |
||
30 | 30 | self::CONFIG_PATH => config_path('lighthouse-utils.php'), |
31 | 31 | ], 'config'); |
32 | 32 | |
33 | - if (! class_exists('CreatePermissionTables')) { |
|
33 | + if (!class_exists('CreatePermissionTables')) { |
|
34 | 34 | $timestamp = date('Y_m_d_His', time()); |
35 | 35 | $this->publishes([ |
36 | - self::MIGRATION_PATH => $this->app->databasePath()."/migrations/{$timestamp}_create_graphql_schema_table.php", |
|
36 | + self::MIGRATION_PATH => $this->app->databasePath() . "/migrations/{$timestamp}_create_graphql_schema_table.php", |
|
37 | 37 | ], 'migrations'); |
38 | 38 | } |
39 | 39 | |
@@ -51,7 +51,7 @@ discard block |
||
51 | 51 | // Merging config doesn't seem to work on arrays, this is our work-around. |
52 | 52 | config()->set('lighthouse.directives', array_merge(config('lighthouse.directives', []), [$this->directiveAppPath])); |
53 | 53 | |
54 | - $this->app->bind('lighthouse-utils', function () { |
|
54 | + $this->app->bind('lighthouse-utils', function() { |
|
55 | 55 | return new LighthouseUtils(); |
56 | 56 | }); |
57 | 57 |
@@ -45,7 +45,7 @@ |
||
45 | 45 | */ |
46 | 46 | public function parseLiteral($valueNode, array $variables = null) |
47 | 47 | { |
48 | - if (! $valueNode instanceof StringValueNode) { |
|
48 | + if (!$valueNode instanceof StringValueNode) { |
|
49 | 49 | throw new Error('Query error: Can only parse strings got: ' . $valueNode->kind, [$valueNode]); |
50 | 50 | } |
51 | 51 |