@@ -43,10 +43,10 @@ |
||
| 43 | 43 | [ |
| 44 | 44 | 'name' => $definition->getName(), |
| 45 | 45 | 'description' => $definition->getDescription(), |
| 46 | - 'fields' => function () use ($definition) { |
|
| 46 | + 'fields' => function() use ($definition) { |
|
| 47 | 47 | return GraphQLBuilder::resolveFields($definition); |
| 48 | 48 | }, |
| 49 | - 'resolveType' => function ($value) { |
|
| 49 | + 'resolveType' => function($value) { |
|
| 50 | 50 | return TypeUtil::resolveObjectType($this->endpoint, $value); |
| 51 | 51 | }, |
| 52 | 52 | ] |
@@ -82,7 +82,7 @@ discard block |
||
| 82 | 82 | * |
| 83 | 83 | * @return null|string |
| 84 | 84 | */ |
| 85 | - public function getClassForType(string $type):?string |
|
| 85 | + public function getClassForType(string $type): ?string |
|
| 86 | 86 | { |
| 87 | 87 | if (isset($this->typeMap[$type])) { |
| 88 | 88 | return $this->typeMap[$type]; |
@@ -110,7 +110,7 @@ discard block |
||
| 110 | 110 | { |
| 111 | 111 | $types = array_filter( |
| 112 | 112 | $this->typeMap, |
| 113 | - function ($val) use ($class) { |
|
| 113 | + function($val) use ($class) { |
|
| 114 | 114 | return $val === $class; |
| 115 | 115 | } |
| 116 | 116 | ); |
@@ -42,10 +42,10 @@ |
||
| 42 | 42 | protected function configure() |
| 43 | 43 | { |
| 44 | 44 | $this->setName('graphql:schema:export') |
| 45 | - ->setDescription('Export your schema.') |
|
| 46 | - ->addOption('endpoint', null, InputOption::VALUE_REQUIRED, 'Name of the endpoint to export', DefinitionRegistry::DEFAULT_ENDPOINT) |
|
| 47 | - ->addOption('output', 'o', InputOption::VALUE_REQUIRED, 'Name of the file to save the schema, e.i. schema.graphql or schema.json') |
|
| 48 | - ->addOption('json', null, InputOption::VALUE_NONE, 'Create json output, automatically used if the output contains json extension'); |
|
| 45 | + ->setDescription('Export your schema.') |
|
| 46 | + ->addOption('endpoint', null, InputOption::VALUE_REQUIRED, 'Name of the endpoint to export', DefinitionRegistry::DEFAULT_ENDPOINT) |
|
| 47 | + ->addOption('output', 'o', InputOption::VALUE_REQUIRED, 'Name of the file to save the schema, e.i. schema.graphql or schema.json') |
|
| 48 | + ->addOption('json', null, InputOption::VALUE_NONE, 'Create json output, automatically used if the output contains json extension'); |
|
| 49 | 49 | } |
| 50 | 50 | |
| 51 | 51 | /** |
@@ -57,11 +57,11 @@ |
||
| 57 | 57 | protected function configure() |
| 58 | 58 | { |
| 59 | 59 | $this->setName('graphql:schema:snapshot') |
| 60 | - ->setDescription('Create a snapshot of your schema to compare using behat tests.') |
|
| 61 | - ->addOption('endpoint', null, InputOption::VALUE_REQUIRED, 'Name of the endpoint to export', DefinitionRegistry::DEFAULT_ENDPOINT) |
|
| 62 | - ->addOption('all', 'a', InputOption::VALUE_NONE, 'Create snapshot for all registered endpoints') |
|
| 63 | - ->addOption('strict', null, InputOption::VALUE_NONE, 'When use strict mode the snapshot must be updated every time your schema change') |
|
| 64 | - ->addOption('features', null, InputOption::VALUE_REQUIRED, 'Path where should be located the generated features and fixtures'); |
|
| 60 | + ->setDescription('Create a snapshot of your schema to compare using behat tests.') |
|
| 61 | + ->addOption('endpoint', null, InputOption::VALUE_REQUIRED, 'Name of the endpoint to export', DefinitionRegistry::DEFAULT_ENDPOINT) |
|
| 62 | + ->addOption('all', 'a', InputOption::VALUE_NONE, 'Create snapshot for all registered endpoints') |
|
| 63 | + ->addOption('strict', null, InputOption::VALUE_NONE, 'When use strict mode the snapshot must be updated every time your schema change') |
|
| 64 | + ->addOption('features', null, InputOption::VALUE_REQUIRED, 'Path where should be located the generated features and fixtures'); |
|
| 65 | 65 | } |
| 66 | 66 | |
| 67 | 67 | /** |
@@ -239,7 +239,7 @@ |
||
| 239 | 239 | public function sendRequest($method, $uri, array $parameters = [], array $files = [], array $server = [], $content = null, $changeHistory = true) |
| 240 | 240 | { |
| 241 | 241 | set_error_handler( |
| 242 | - function ($level, $message, $errFile, $errLine) { |
|
| 242 | + function($level, $message, $errFile, $errLine) { |
|
| 243 | 243 | if ($this->deprecationAdviser) { |
| 244 | 244 | $this->deprecationAdviser->addWarning($message, $errFile, $errLine); |
| 245 | 245 | } |
@@ -74,7 +74,7 @@ discard block |
||
| 74 | 74 | ->beforeNormalization() |
| 75 | 75 | ->ifString() |
| 76 | 76 | ->then( |
| 77 | - function ($v) { |
|
| 77 | + function($v) { |
|
| 78 | 78 | return [$v]; |
| 79 | 79 | } |
| 80 | 80 | ) |
@@ -87,14 +87,14 @@ discard block |
||
| 87 | 87 | ->beforeNormalization() |
| 88 | 88 | ->ifString() |
| 89 | 89 | ->then( |
| 90 | - function ($v) { |
|
| 90 | + function($v) { |
|
| 91 | 91 | return [$v]; |
| 92 | 92 | } |
| 93 | 93 | ) |
| 94 | 94 | ->end() |
| 95 | 95 | ->validate() |
| 96 | 96 | ->ifTrue( |
| 97 | - function (array $value) { |
|
| 97 | + function(array $value) { |
|
| 98 | 98 | foreach ($value as $val) { |
| 99 | 99 | try { |
| 100 | 100 | preg_match($val, null); |
@@ -111,14 +111,14 @@ discard block |
||
| 111 | 111 | ->beforeNormalization() |
| 112 | 112 | ->ifString() |
| 113 | 113 | ->then( |
| 114 | - function ($v) { |
|
| 114 | + function($v) { |
|
| 115 | 115 | return [$v]; |
| 116 | 116 | } |
| 117 | 117 | ) |
| 118 | 118 | ->end() |
| 119 | 119 | ->validate() |
| 120 | 120 | ->ifTrue( |
| 121 | - function (array $value) { |
|
| 121 | + function(array $value) { |
|
| 122 | 122 | foreach ($value as $val) { |
| 123 | 123 | try { |
| 124 | 124 | preg_match($val, null); |
@@ -136,7 +136,7 @@ discard block |
||
| 136 | 136 | ->useAttributeAsKey('name') |
| 137 | 137 | ->validate() |
| 138 | 138 | ->ifTrue( |
| 139 | - function ($v) { |
|
| 139 | + function($v) { |
|
| 140 | 140 | return array_key_exists('default', $v); |
| 141 | 141 | } |
| 142 | 142 | )->thenInvalid('"default" can\'t be used as endpoint name, the system internally use this endpoint name to store the entire schema.') |
@@ -148,7 +148,7 @@ discard block |
||
| 148 | 148 | ->beforeNormalization() |
| 149 | 149 | ->ifString() |
| 150 | 150 | ->then( |
| 151 | - function ($v) { |
|
| 151 | + function($v) { |
|
| 152 | 152 | return preg_split('/\s*,\s*/', $v); |
| 153 | 153 | } |
| 154 | 154 | ) |
@@ -165,7 +165,7 @@ discard block |
||
| 165 | 165 | ->beforeNormalization() |
| 166 | 166 | ->ifString() |
| 167 | 167 | ->then( |
| 168 | - function ($v) { |
|
| 168 | + function($v) { |
|
| 169 | 169 | return preg_split('/\s*,\s*/', $v); |
| 170 | 170 | } |
| 171 | 171 | ) |
@@ -50,50 +50,50 @@ discard block |
||
| 50 | 50 | protected function configureSubscriptions(NodeBuilder $root) |
| 51 | 51 | { |
| 52 | 52 | $subscriptions = $root->arrayNode('subscriptions') |
| 53 | - ->info('Manage subscriptions settings') |
|
| 54 | - ->canBeDisabled() |
|
| 55 | - ->addDefaultsIfNotSet() |
|
| 56 | - ->children(); |
|
| 53 | + ->info('Manage subscriptions settings') |
|
| 54 | + ->canBeDisabled() |
|
| 55 | + ->addDefaultsIfNotSet() |
|
| 56 | + ->children(); |
|
| 57 | 57 | |
| 58 | 58 | $subscriptions->scalarNode('mercure_hub')->defaultValue('default'); |
| 59 | 59 | $subscriptions->scalarNode('pubsub_handler')->defaultValue(RedisPubSubHandler::class); |
| 60 | 60 | $redis = $subscriptions->arrayNode('redis')->info('Configure redis server to use as subscription handler') |
| 61 | - ->addDefaultsIfNotSet() |
|
| 62 | - ->children(); |
|
| 61 | + ->addDefaultsIfNotSet() |
|
| 62 | + ->children(); |
|
| 63 | 63 | |
| 64 | 64 | $redis->scalarNode('host')->defaultValue('localhost'); |
| 65 | 65 | $redis->integerNode('port')->defaultValue(6379); |
| 66 | 66 | $redis->scalarNode('prefix')->defaultValue('GraphQLSubscription:') |
| 67 | - ->info('Define custom prefix to avoid collisions between applications'); |
|
| 67 | + ->info('Define custom prefix to avoid collisions between applications'); |
|
| 68 | 68 | } |
| 69 | 69 | |
| 70 | 70 | protected function configureErrorHandling(NodeBuilder $root) |
| 71 | 71 | { |
| 72 | 72 | $errorHandling = $root->arrayNode('error_handling') |
| 73 | - ->info('It is important to handle errors and when possible, report these errors back to your users for information. ') |
|
| 74 | - ->addDefaultsIfNotSet() |
|
| 75 | - ->children(); |
|
| 73 | + ->info('It is important to handle errors and when possible, report these errors back to your users for information. ') |
|
| 74 | + ->addDefaultsIfNotSet() |
|
| 75 | + ->children(); |
|
| 76 | 76 | |
| 77 | 77 | $errorHandling->enumNode('validation_messages') |
| 78 | - ->values(['error', 'payload', 'both']) |
|
| 79 | - ->info('Where should be displayed validation messages.') |
|
| 80 | - ->defaultValue('error'); |
|
| 78 | + ->values(['error', 'payload', 'both']) |
|
| 79 | + ->info('Where should be displayed validation messages.') |
|
| 80 | + ->defaultValue('error'); |
|
| 81 | 81 | |
| 82 | 82 | //@deprecated since v1.1 snd should be deleted in 2.0, this is a compatibility flag |
| 83 | 83 | $errorHandling->booleanNode('jwt_auth_failure_compatibility') |
| 84 | - ->info('Keep BC with oldest version of JWT Authentication errors') |
|
| 85 | - ->setDeprecated('Since v1.1 and will will be removed in the next mayor release') |
|
| 86 | - ->defaultFalse(); |
|
| 84 | + ->info('Keep BC with oldest version of JWT Authentication errors') |
|
| 85 | + ->setDeprecated('Since v1.1 and will will be removed in the next mayor release') |
|
| 86 | + ->defaultFalse(); |
|
| 87 | 87 | |
| 88 | 88 | $errorHandling->booleanNode('show_trace')->info('Show error trace in debug mode')->defaultFalse(); |
| 89 | 89 | |
| 90 | 90 | $errorHandling->scalarNode('formatter') |
| 91 | - ->info('Formatter is responsible for converting instances of Error to an array') |
|
| 92 | - ->defaultValue(DefaultErrorFormatter::class); |
|
| 91 | + ->info('Formatter is responsible for converting instances of Error to an array') |
|
| 92 | + ->defaultValue(DefaultErrorFormatter::class); |
|
| 93 | 93 | |
| 94 | 94 | $errorHandling->scalarNode('handler') |
| 95 | - ->info('Handler is useful for error filtering and logging.') |
|
| 96 | - ->defaultValue(DefaultErrorHandler::class); |
|
| 95 | + ->info('Handler is useful for error filtering and logging.') |
|
| 96 | + ->defaultValue(DefaultErrorHandler::class); |
|
| 97 | 97 | |
| 98 | 98 | $controlledErrors = $errorHandling |
| 99 | 99 | ->arrayNode('controlled_errors') |
@@ -179,44 +179,44 @@ discard block |
||
| 179 | 179 | protected function configureEndpoints(NodeBuilder $root) |
| 180 | 180 | { |
| 181 | 181 | $endpoints = $root->arrayNode('endpoints') |
| 182 | - ->useAttributeAsKey('name') |
|
| 183 | - ->validate() |
|
| 184 | - ->ifTrue( |
|
| 185 | - function ($v) { |
|
| 186 | - return array_key_exists('default', $v); |
|
| 187 | - } |
|
| 188 | - )->thenInvalid('"default" can\'t be used as endpoint name, the system internally use this endpoint name to store the entire schema.') |
|
| 189 | - ->end() |
|
| 190 | - ->arrayPrototype() |
|
| 191 | - ->children(); |
|
| 182 | + ->useAttributeAsKey('name') |
|
| 183 | + ->validate() |
|
| 184 | + ->ifTrue( |
|
| 185 | + function ($v) { |
|
| 186 | + return array_key_exists('default', $v); |
|
| 187 | + } |
|
| 188 | + )->thenInvalid('"default" can\'t be used as endpoint name, the system internally use this endpoint name to store the entire schema.') |
|
| 189 | + ->end() |
|
| 190 | + ->arrayPrototype() |
|
| 191 | + ->children(); |
|
| 192 | 192 | |
| 193 | 193 | $endpoints->arrayNode('roles') |
| 194 | - ->beforeNormalization() |
|
| 195 | - ->ifString() |
|
| 196 | - ->then( |
|
| 197 | - function ($v) { |
|
| 198 | - return preg_split('/\s*,\s*/', $v); |
|
| 199 | - } |
|
| 200 | - ) |
|
| 201 | - ->end() |
|
| 202 | - ->prototype('scalar') |
|
| 203 | - ->end(); |
|
| 194 | + ->beforeNormalization() |
|
| 195 | + ->ifString() |
|
| 196 | + ->then( |
|
| 197 | + function ($v) { |
|
| 198 | + return preg_split('/\s*,\s*/', $v); |
|
| 199 | + } |
|
| 200 | + ) |
|
| 201 | + ->end() |
|
| 202 | + ->prototype('scalar') |
|
| 203 | + ->end(); |
|
| 204 | 204 | |
| 205 | 205 | $endpoints->scalarNode('host')->example('^api\.backend\.'); |
| 206 | 206 | $endpoints->scalarNode('path')->example('/backend'); |
| 207 | 207 | |
| 208 | 208 | $root->arrayNode('endpoint_alias') |
| 209 | - ->info('Use alias to refer to multiple endpoints using only one name') |
|
| 210 | - ->useAttributeAsKey('name') |
|
| 211 | - ->beforeNormalization() |
|
| 212 | - ->ifString() |
|
| 213 | - ->then( |
|
| 214 | - function ($v) { |
|
| 215 | - return preg_split('/\s*,\s*/', $v); |
|
| 216 | - } |
|
| 217 | - ) |
|
| 218 | - ->end() |
|
| 219 | - ->variablePrototype(); |
|
| 209 | + ->info('Use alias to refer to multiple endpoints using only one name') |
|
| 210 | + ->useAttributeAsKey('name') |
|
| 211 | + ->beforeNormalization() |
|
| 212 | + ->ifString() |
|
| 213 | + ->then( |
|
| 214 | + function ($v) { |
|
| 215 | + return preg_split('/\s*,\s*/', $v); |
|
| 216 | + } |
|
| 217 | + ) |
|
| 218 | + ->end() |
|
| 219 | + ->variablePrototype(); |
|
| 220 | 220 | |
| 221 | 221 | $root->scalarNode('endpoint_default')->info('Endpoint to apply to all definitions without explicit endpoint.'); |
| 222 | 222 | |
@@ -227,7 +227,7 @@ discard block |
||
| 227 | 227 | $graphiql = $root->arrayNode('graphiql')->addDefaultsIfNotSet()->children(); |
| 228 | 228 | |
| 229 | 229 | $graphiql->scalarNode('title') |
| 230 | - ->defaultValue('GraphQL API Explorer'); |
|
| 230 | + ->defaultValue('GraphQL API Explorer'); |
|
| 231 | 231 | |
| 232 | 232 | $graphiql |
| 233 | 233 | ->scalarNode('data_warning_message') |
@@ -255,61 +255,61 @@ discard block |
||
| 255 | 255 | ->defaultFalse(); |
| 256 | 256 | |
| 257 | 257 | $authentication->scalarNode('login_message') |
| 258 | - ->defaultValue('Start exploring GraphQL API queries using your account’s data now.'); |
|
| 258 | + ->defaultValue('Start exploring GraphQL API queries using your account’s data now.'); |
|
| 259 | 259 | |
| 260 | 260 | $authenticationProvider = $authentication->arrayNode('provider')->children(); |
| 261 | 261 | |
| 262 | 262 | //the updated version of `jwt` to use lexik authentication bundle |
| 263 | 263 | $lexikJwt = $authenticationProvider->arrayNode('lexik_jwt') |
| 264 | - ->canBeEnabled() |
|
| 265 | - ->children(); |
|
| 264 | + ->canBeEnabled() |
|
| 265 | + ->children(); |
|
| 266 | 266 | |
| 267 | 267 | $lexikJwt->scalarNode('user_provider') |
| 268 | - ->isRequired() |
|
| 269 | - ->info('Name of the user provider to use'); |
|
| 268 | + ->isRequired() |
|
| 269 | + ->info('Name of the user provider to use'); |
|
| 270 | 270 | |
| 271 | 271 | $lexikJwt->scalarNode('username_label') |
| 272 | - ->defaultValue('Username'); |
|
| 272 | + ->defaultValue('Username'); |
|
| 273 | 273 | |
| 274 | 274 | $lexikJwt->scalarNode('password_label') |
| 275 | - ->defaultValue('Password'); |
|
| 275 | + ->defaultValue('Password'); |
|
| 276 | 276 | |
| 277 | 277 | $authenticationProvider->scalarNode('custom') |
| 278 | - ->defaultNull() |
|
| 279 | - ->info('Configure custom service to use as authentication provider'); |
|
| 278 | + ->defaultNull() |
|
| 279 | + ->info('Configure custom service to use as authentication provider'); |
|
| 280 | 280 | |
| 281 | 281 | //deprecated since v1.1 and should be deleted in v2.0 |
| 282 | 282 | $jwt = $authenticationProvider->arrayNode('jwt') |
| 283 | - ->setDeprecated('Use lexik_jwt instead, this provider will be removed in the next mayor release.') |
|
| 284 | - ->canBeEnabled() |
|
| 285 | - ->children(); |
|
| 283 | + ->setDeprecated('Use lexik_jwt instead, this provider will be removed in the next mayor release.') |
|
| 284 | + ->canBeEnabled() |
|
| 285 | + ->children(); |
|
| 286 | 286 | |
| 287 | 287 | $jwtLogin = $jwt->arrayNode('login')->children(); |
| 288 | 288 | |
| 289 | 289 | $jwtLogin->scalarNode('url') |
| 290 | - ->info('Route name or URI to make the login process to retrieve the token.') |
|
| 291 | - ->isRequired(); |
|
| 290 | + ->info('Route name or URI to make the login process to retrieve the token.') |
|
| 291 | + ->isRequired(); |
|
| 292 | 292 | |
| 293 | 293 | $jwtLogin->scalarNode('username_parameter') |
| 294 | - ->defaultValue('username'); |
|
| 294 | + ->defaultValue('username'); |
|
| 295 | 295 | |
| 296 | 296 | $jwtLogin->scalarNode('username_label') |
| 297 | - ->defaultValue('Username'); |
|
| 297 | + ->defaultValue('Username'); |
|
| 298 | 298 | |
| 299 | 299 | $jwtLogin->scalarNode('password_parameter') |
| 300 | - ->defaultValue('password'); |
|
| 300 | + ->defaultValue('password'); |
|
| 301 | 301 | |
| 302 | 302 | $jwtLogin->scalarNode('password_label') |
| 303 | - ->defaultValue('Password'); |
|
| 303 | + ->defaultValue('Password'); |
|
| 304 | 304 | |
| 305 | 305 | $jwtLogin->enumNode('parameters_in') |
| 306 | - ->values(['form', 'query', 'header']) |
|
| 307 | - ->info('How pass parameters to request the token') |
|
| 308 | - ->defaultValue('form'); |
|
| 306 | + ->values(['form', 'query', 'header']) |
|
| 307 | + ->info('How pass parameters to request the token') |
|
| 308 | + ->defaultValue('form'); |
|
| 309 | 309 | |
| 310 | 310 | $jwtLogin->scalarNode('response_token_path') |
| 311 | - ->defaultValue('token') |
|
| 312 | - ->info('Where the token should be located in the response in case of JSON, set null if the response is the token.'); |
|
| 311 | + ->defaultValue('token') |
|
| 312 | + ->info('Where the token should be located in the response in case of JSON, set null if the response is the token.'); |
|
| 313 | 313 | |
| 314 | 314 | $jwtRequests = $jwt->arrayNode('requests')->addDefaultsIfNotSet()->children(); |
| 315 | 315 | |
@@ -348,25 +348,25 @@ discard block |
||
| 348 | 348 | { |
| 349 | 349 | $pagination = $root->arrayNode('pagination')->addDefaultsIfNotSet()->children(); |
| 350 | 350 | $pagination->integerNode('limit') |
| 351 | - ->defaultValue(100)->info('Maximum limit allowed for all paginations'); |
|
| 351 | + ->defaultValue(100)->info('Maximum limit allowed for all paginations'); |
|
| 352 | 352 | } |
| 353 | 353 | |
| 354 | 354 | protected function configurePluginNamespaceGlobalConfig(NodeBuilder $root) |
| 355 | 355 | { |
| 356 | 356 | $namespaces = $root->arrayNode('namespaces') |
| 357 | - ->info( |
|
| 358 | - 'Group GraphQL schema using namespaced schemas. |
|
| 357 | + ->info( |
|
| 358 | + 'Group GraphQL schema using namespaced schemas. |
|
| 359 | 359 | On large schemas is helpful to keep schemas grouped by bundle and node' |
| 360 | - ) |
|
| 361 | - ->canBeEnabled() |
|
| 362 | - ->addDefaultsIfNotSet() |
|
| 363 | - ->children(); |
|
| 360 | + ) |
|
| 361 | + ->canBeEnabled() |
|
| 362 | + ->addDefaultsIfNotSet() |
|
| 363 | + ->children(); |
|
| 364 | 364 | |
| 365 | 365 | $bundles = $namespaces->arrayNode('bundles') |
| 366 | - ->info('Group each bundle into a separate schema definition') |
|
| 367 | - ->canBeDisabled() |
|
| 368 | - ->addDefaultsIfNotSet() |
|
| 369 | - ->children(); |
|
| 366 | + ->info('Group each bundle into a separate schema definition') |
|
| 367 | + ->canBeDisabled() |
|
| 368 | + ->addDefaultsIfNotSet() |
|
| 369 | + ->children(); |
|
| 370 | 370 | |
| 371 | 371 | $bundles->scalarNode('query_suffix') |
| 372 | 372 | ->info('The following suffix will be used for bundle query groups') |
@@ -401,29 +401,29 @@ discard block |
||
| 401 | 401 | ->children(); |
| 402 | 402 | |
| 403 | 403 | $nodes->scalarNode('query_suffix') |
| 404 | - ->info('The following suffix will be used to create the name for queries to the same node') |
|
| 405 | - ->defaultValue('Query'); |
|
| 404 | + ->info('The following suffix will be used to create the name for queries to the same node') |
|
| 405 | + ->defaultValue('Query'); |
|
| 406 | 406 | |
| 407 | 407 | $nodes->scalarNode('mutation_suffix') |
| 408 | - ->info('The following suffix will be used to create the name for mutations to the same node') |
|
| 409 | - ->defaultValue('Mutation'); |
|
| 408 | + ->info('The following suffix will be used to create the name for mutations to the same node') |
|
| 409 | + ->defaultValue('Mutation'); |
|
| 410 | 410 | |
| 411 | 411 | $nodes->scalarNode('subscription_suffix') |
| 412 | - ->info('The following suffix will be used to create the name for subscriptions to the same node') |
|
| 413 | - ->defaultValue('Subscriptions'); |
|
| 412 | + ->info('The following suffix will be used to create the name for subscriptions to the same node') |
|
| 413 | + ->defaultValue('Subscriptions'); |
|
| 414 | 414 | |
| 415 | 415 | $nodes->variableNode('ignore') |
| 416 | - ->info('The following nodes will be ignore for grouping, all definitions will be placed in the root query or mutation') |
|
| 417 | - ->defaultValue(['Node']); |
|
| 416 | + ->info('The following nodes will be ignore for grouping, all definitions will be placed in the root query or mutation') |
|
| 417 | + ->defaultValue(['Node']); |
|
| 418 | 418 | |
| 419 | 419 | $nodes->arrayNode('aliases') |
| 420 | - ->info( |
|
| 421 | - 'Define aliases for nodes to set definitions inside other desired node name. |
|
| 420 | + ->info( |
|
| 421 | + 'Define aliases for nodes to set definitions inside other desired node name. |
|
| 422 | 422 | Can be used to group multiple nodes or publish a node with a different group name' |
| 423 | - ) |
|
| 424 | - ->example('InvoiceItem: Invoice') |
|
| 425 | - ->useAttributeAsKey('name') |
|
| 426 | - ->prototype('scalar'); |
|
| 423 | + ) |
|
| 424 | + ->example('InvoiceItem: Invoice') |
|
| 425 | + ->useAttributeAsKey('name') |
|
| 426 | + ->prototype('scalar'); |
|
| 427 | 427 | } |
| 428 | 428 | |
| 429 | 429 | private function configureSecurity(NodeBuilder $rootNode) |
@@ -469,13 +469,13 @@ discard block |
||
| 469 | 469 | ->children(); |
| 470 | 470 | |
| 471 | 471 | $bcNode->variableNode('filters') |
| 472 | - ->info('Keep deprecated "filters" argument in collections') |
|
| 473 | - ->setDeprecated('v1.2') |
|
| 474 | - ->defaultFalse(); |
|
| 472 | + ->info('Keep deprecated "filters" argument in collections') |
|
| 473 | + ->setDeprecated('v1.2') |
|
| 474 | + ->defaultFalse(); |
|
| 475 | 475 | |
| 476 | 476 | $bcNode->variableNode('orderBy') |
| 477 | - ->info('Keep deprecated "orderBy" argument in collections') |
|
| 478 | - ->setDeprecated('v1.2') |
|
| 479 | - ->defaultFalse(); |
|
| 477 | + ->info('Keep deprecated "orderBy" argument in collections') |
|
| 478 | + ->setDeprecated('v1.2') |
|
| 479 | + ->defaultFalse(); |
|
| 480 | 480 | } |
| 481 | 481 | } |
@@ -46,9 +46,9 @@ |
||
| 46 | 46 | |
| 47 | 47 | $styleGuide = new TableStyle(); |
| 48 | 48 | $styleGuide->setHorizontalBorderChar('') |
| 49 | - ->setVerticalBorderChar('|') |
|
| 50 | - ->setCrossingChar(' ') |
|
| 51 | - ->setCellHeaderFormat('%s'); |
|
| 49 | + ->setVerticalBorderChar('|') |
|
| 50 | + ->setCrossingChar(' ') |
|
| 51 | + ->setCellHeaderFormat('%s'); |
|
| 52 | 52 | |
| 53 | 53 | $table->setStyle($styleGuide); |
| 54 | 54 | $table->setRows($rows); |
@@ -35,7 +35,7 @@ |
||
| 35 | 35 | |
| 36 | 36 | $table = new Table($output); |
| 37 | 37 | $table->setHeaders(['Code', 'Text', 'Description']) |
| 38 | - ->setRows($rows); |
|
| 38 | + ->setRows($rows); |
|
| 39 | 39 | $table->render(); |
| 40 | 40 | } |
| 41 | 41 | } |
@@ -49,9 +49,9 @@ |
||
| 49 | 49 | protected function configure() |
| 50 | 50 | { |
| 51 | 51 | $this->setName('graphql:error:list') |
| 52 | - ->setDescription('View, export and control your API errors.') |
|
| 53 | - ->addOption('exporter', 'x', InputOption::VALUE_REQUIRED, 'Exporter to user', 'console') |
|
| 54 | - ->addOption('output', 'o', InputOption::VALUE_REQUIRED, 'Name of the file to save the error list, e.i. error_codes.md'); |
|
| 52 | + ->setDescription('View, export and control your API errors.') |
|
| 53 | + ->addOption('exporter', 'x', InputOption::VALUE_REQUIRED, 'Exporter to user', 'console') |
|
| 54 | + ->addOption('output', 'o', InputOption::VALUE_REQUIRED, 'Name of the file to save the error list, e.i. error_codes.md'); |
|
| 55 | 55 | } |
| 56 | 56 | |
| 57 | 57 | /** |
@@ -59,7 +59,7 @@ |
||
| 59 | 59 | */ |
| 60 | 60 | protected function execute(InputInterface $input, OutputInterface $output) |
| 61 | 61 | { |
| 62 | - $this->errorManager->clear();//force reload |
|
| 62 | + $this->errorManager->clear(); //force reload |
|
| 63 | 63 | $errors = $this->errorManager->all(); |
| 64 | 64 | |
| 65 | 65 | $result = $output; |