Skip to content

Commit

Permalink
NGSTACK-842: apply null-safe chaining to account for config builder A…
Browse files Browse the repository at this point in the history
…PI deficiencies
  • Loading branch information
pspanja committed Jun 28, 2024
1 parent 63ba66c commit 39946b4
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions bundle/DependencyInjection/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ private function addEnabled(ArrayNodeDefinition $nodeDefinition): void
->booleanNode('enabled')
->defaultFalse()
->end()
->end();
?->end();
}

private function addHandlerSection(ArrayNodeDefinition $nodeDefinition): void
Expand All @@ -52,7 +52,7 @@ private function addHandlerSection(ArrayNodeDefinition $nodeDefinition): void
->info('Configure handler for scheduled visibility mechanism')
->defaultValue('content')
->end()
->end();
?->end();
}

private function addContentTypesSection(ArrayNodeDefinition $nodeDefinition): void
Expand All @@ -69,10 +69,10 @@ private function addContentTypesSection(ArrayNodeDefinition $nodeDefinition): vo
->booleanNode('all')
->defaultFalse()
->end()
->arrayNode('allowed')
?->arrayNode('allowed')
->scalarPrototype()
->end()
->end()
?->end()
->end()
->end();
}
Expand All @@ -92,7 +92,7 @@ private function addSectionsSection(ArrayNodeDefinition $nodeDefinition): void
->integerNode('section_id')
->defaultValue(0)
->end()
->end()
?->end()
->end()
->arrayNode('hidden')
->info('Configure hidden section id used for scheduled visibility mechanism')
Expand All @@ -101,7 +101,7 @@ private function addSectionsSection(ArrayNodeDefinition $nodeDefinition): void
->integerNode('section_id')
->defaultValue(0)
->end()
->end()
?->end()
->end()
->end()
->end()
Expand All @@ -119,14 +119,14 @@ private function addObjectStatesSection(ArrayNodeDefinition $nodeDefinition): vo
->integerNode('object_state_group_id')
->defaultValue(0)
->end()
->arrayNode('visible')
?->arrayNode('visible')
->info('Configure visible object states and groups used for scheduled visibility mechanism')
->addDefaultsIfNotSet()
->children()
->integerNode('object_state_id')
->defaultValue(0)
->end()
->end()
?->end()
->end()
->arrayNode('hidden')
->info('Configure hidden bject states and groups used for scheduled visibility mechanism')
Expand All @@ -135,7 +135,7 @@ private function addObjectStatesSection(ArrayNodeDefinition $nodeDefinition): vo
->integerNode('object_state_id')
->defaultValue(0)
->end()
->end()
?->end()
->end()
->end()
->end()
Expand Down

0 comments on commit 39946b4

Please sign in to comment.