From b64eac0fa8ac87d43dc2e82602748691e38d60f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A1chym=20Tou=C5=A1ek?= Date: Tue, 18 Jun 2019 10:40:30 +0200 Subject: [PATCH] Fix Configuration --- src/DependencyInjection/Configuration.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/DependencyInjection/Configuration.php b/src/DependencyInjection/Configuration.php index aca74b2..294c5b5 100644 --- a/src/DependencyInjection/Configuration.php +++ b/src/DependencyInjection/Configuration.php @@ -66,7 +66,7 @@ private function addServiceBusSection(string $type, ArrayNodeDefinition $node): ->prototype('scalar') ->beforeNormalization() ->ifTrue(function ($v) { - return strpos($v, '@') === 0; + return is_string($v) && strpos($v, '@') === 0; }) ->then(function ($v) { return substr($v, 1); @@ -77,7 +77,7 @@ private function addServiceBusSection(string $type, ArrayNodeDefinition $node): $handlerNode ->beforeNormalization() ->ifTrue(function ($v) { - return strpos($v, '@') === 0; + return is_string($v) && strpos($v, '@') === 0; }) ->then(function ($v) { return substr($v, 1); @@ -98,7 +98,7 @@ private function addServiceBusSection(string $type, ArrayNodeDefinition $node): ->scalarNode('message_factory') ->beforeNormalization() ->ifTrue(function ($v) { - return strpos($v, '@') === 0; + return is_string($v) && strpos($v, '@') === 0; }) ->then(function ($v) { return substr($v, 1); @@ -109,7 +109,7 @@ private function addServiceBusSection(string $type, ArrayNodeDefinition $node): ->scalarNode('message_data_converter') ->beforeNormalization() ->ifTrue(function ($v) { - return strpos($v, '@') === 0; + return is_string($v) && strpos($v, '@') === 0; }) ->then(function ($v) { return substr($v, 1); @@ -120,7 +120,7 @@ private function addServiceBusSection(string $type, ArrayNodeDefinition $node): ->scalarNode('message_converter') ->beforeNormalization() ->ifTrue(function ($v) { - return strpos($v, '@') === 0; + return is_string($v) && strpos($v, '@') === 0; }) ->then(function ($v) { return substr($v, 1); @@ -138,7 +138,7 @@ private function addServiceBusSection(string $type, ArrayNodeDefinition $node): ->prototype('scalar') ->beforeNormalization() ->ifTrue(function ($v) { - return strpos($v, '@') === 0; + return is_string($v) && strpos($v, '@') === 0; }) ->then(function ($v) { return substr($v, 1); @@ -153,7 +153,7 @@ private function addServiceBusSection(string $type, ArrayNodeDefinition $node): ->scalarNode('type') ->beforeNormalization() ->ifTrue(function ($v) { - return strpos($v, '@') === 0; + return is_string($v) && strpos($v, '@') === 0; }) ->then(function ($v) { return substr($v, 1); @@ -164,7 +164,7 @@ private function addServiceBusSection(string $type, ArrayNodeDefinition $node): ->scalarNode('async_switch') ->beforeNormalization() ->ifTrue(function ($v) { - return strpos($v, '@') === 0; + return is_string($v) && strpos($v, '@') === 0; }) ->then(function ($v) { return substr($v, 1);