Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use short config syntax for factories #7213

Closed
wants to merge 1 commit into from
Closed

use short config syntax for factories #7213

wants to merge 1 commit into from

Conversation

snoek09
Copy link

@snoek09 snoek09 commented Dec 3, 2016

This fixes #7208.


.. versionadded:: 3.2
The ``factory_service:method_name`` syntax for the YAML configuration format
was introduced in Symfony 3.2.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like this was available since the introduction of the new factory syntax in Symfony 2.6: https://github.com/symfony/symfony/blob/2.7/src/Symfony/Component/DependencyInjection/Loader/YamlFileLoader.php#L195-L198

@@ -106,6 +106,23 @@ configure the service container to use the
the configured class name may be used by compiler passes and therefore
should be set to a sensible value.

.. note::

The traditional configurator syntax in YAML files used an array to define
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

configuration syntax

@snoek09 snoek09 changed the base branch from 3.2 to 2.8 December 3, 2016 10:40
@snoek09 snoek09 changed the base branch from 2.8 to 3.2 December 3, 2016 10:40
@snoek09 snoek09 changed the base branch from 3.2 to 2.8 December 3, 2016 11:19
@snoek09 snoek09 changed the base branch from 2.8 to 3.2 December 3, 2016 11:19
@wouterj
Copy link
Member

wouterj commented Dec 3, 2016

Thanks @snoek09!

👍
status: reviewed


.. versionadded:: 2.6
The ``factory_service:method_name`` syntax for the YAML configuration format
was introduced in Symfony 2.6.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The versionadded directive is not needed here.

Copy link
Member

@javiereguiluz javiereguiluz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@xabbuh
Copy link
Member

xabbuh commented Dec 3, 2016

👍

@xabbuh
Copy link
Member

xabbuh commented Dec 12, 2016

Thank you @snoek09.

@xabbuh xabbuh closed this Dec 12, 2016
xabbuh added a commit that referenced this pull request Dec 12, 2016
This PR was submitted for the 3.2 branch but it was merged into the 2.7 branch instead (closes #7213).

Discussion
----------

use short config syntax for factories

This fixes #7208.

Commits
-------

9348d16 use short config syntax for factories
@snoek09 snoek09 deleted the 7208-factories-short-config-syntax branch December 13, 2016 07:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants