Skip to content

Commit 47054b3

Browse files
committed
fix missing comma in YamlDumper
1 parent 60ed58d commit 47054b3

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

Dumper/YamlDumper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ private function addService($id, $definition)
8585
foreach ($attributes as $key => $value) {
8686
$att[] = sprintf('%s: %s', $this->dumper->dump($key), $this->dumper->dump($value));
8787
}
88-
$att = $att ? ', '.implode(' ', $att) : '';
88+
$att = $att ? ', '.implode(', ', $att) : '';
8989

9090
$tagsCode .= sprintf(" - { name: %s%s }\n", $this->dumper->dump($name), $att);
9191
}

Tests/Fixtures/containers/container9.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
$container->
1212
register('foo', 'FooClass')->
1313
addTag('foo', array('foo' => 'foo'))->
14-
addTag('foo', array('bar' => 'bar'))->
14+
addTag('foo', array('bar' => 'bar', 'baz' => 'baz'))->
1515
setFactoryClass('FooClass')->
1616
setFactoryMethod('getInstance')->
1717
setArguments(array('foo', new Reference('foo.baz'), array('%foo%' => 'foo is %foo%', 'foobar' => '%foo%'), true, new Reference('service_container')))->

Tests/Fixtures/xml/services9.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<services>
99
<service id="foo" class="FooClass" factory-method="getInstance" factory-class="FooClass">
1010
<tag name="foo" foo="foo"/>
11-
<tag name="foo" bar="bar"/>
11+
<tag name="foo" bar="bar" baz="baz"/>
1212
<argument>foo</argument>
1313
<argument type="service" id="foo.baz"/>
1414
<argument type="collection">

Tests/Fixtures/yaml/services9.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ services:
88
class: FooClass
99
tags:
1010
- { name: foo, foo: foo }
11-
- { name: foo, bar: bar }
11+
- { name: foo, bar: bar, baz: baz }
1212
factory_class: FooClass
1313
factory_method: getInstance
1414
arguments: [foo, '@foo.baz', { '%foo%': 'foo is %foo%', foobar: '%foo%' }, true, '@service_container']

0 commit comments

Comments
 (0)