-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[HttpKernel] Extract method to instantiate controller in ControllerResolver #12022
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
Merged
fabpot
merged 1 commit into
symfony:master
from
danharper:extract-method-controller-resolver
Sep 25, 2014
Merged
[HttpKernel] Extract method to instantiate controller in ControllerResolver #12022
fabpot
merged 1 commit into
symfony:master
from
danharper:extract-method-controller-resolver
Sep 25, 2014
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…Resolver correct naming
Thank you @danharper. |
fabpot
added a commit
that referenced
this pull request
Sep 25, 2014
…in ControllerResolver (danharper) This PR was merged into the 2.6-dev branch. Discussion ---------- [HttpKernel] Extract method to instantiate controller in ControllerResolver Replaces #10814 to merge into `master` instead of `2.3`. --- | Q | A | ------------- | --- | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | | License | MIT | Doc PR | Currently it's required to duplicate the entirety of the `getController()` and `createController()` methods just to replace the call to `new` (e.g. with container resolution, instead). Now it's possible to just override the `instantiateController()` method. Commits ------- 88274df [HttpKernel] Extract method to make callable controller in ControllerResolver
stavichenko
added a commit
to stavichenko/symfony
that referenced
this pull request
Feb 2, 2015
…iate controller class in bundle's controller resolver
fabpot
added a commit
that referenced
this pull request
Feb 5, 2015
…vided in (#12022) (stavichenko) This PR was merged into the 2.6 branch. Discussion ---------- [HttpKernel] Added use of instantiateController method provided in (#12022) | Q | A | ------------- | --- | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | | License | MIT | Doc PR | Commits ------- aa6538a [HttpKernel] Added use of provided by #12022 method to instantiate controller class in bundle's controller resolver
fabpot
added a commit
that referenced
this pull request
Feb 5, 2015
* 2.6: (46 commits) fixxed order of usage [2.7] [Form] Replaced calls to array_search() by in_array() where is no need to get the index [Process] Make test AbstractProcessTest::testStartAfterATimeout useful again removed non-sense example Fixes small typo. [Validator] Remove unnecessary include in tests [HttpFoundation] minor: clarify Request::getUrlencodedPrefix() regex fixed typo [Validator] fix DOS-style line endings Drop useless execution bit bumped Symfony version to 2.6.5 [Serializer] update changelog updated VERSION for 2.6.4 updated CHANGELOG for 2.6.4 bumped Symfony version to 2.5.11 [HttpKernel] Added use of provided by #12022 method to instantiate controller class in bundle's controller resolver updated VERSION for 2.5.10 updated CHANGELOG for 2.5.10 [Validator] Add a Russian translation for invalid charset message [2.3] [Validator] spanish translation for invalid charset message ... Conflicts: src/Symfony/Bridge/Doctrine/Validator/Constraints/UniqueEntityValidator.php src/Symfony/Component/HttpKernel/Exception/FatalErrorException.php src/Symfony/Component/HttpKernel/Exception/FlattenException.php src/Symfony/Component/HttpKernel/Kernel.php src/Symfony/Component/Routing/Tests/Generator/UrlGeneratorTest.php src/Symfony/Component/Validator/Resources/translations/validators.de.xlf src/Symfony/Component/Validator/Resources/translations/validators.en.xlf src/Symfony/Component/Validator/Resources/translations/validators.es.xlf src/Symfony/Component/Validator/Resources/translations/validators.fr.xlf src/Symfony/Component/Validator/Resources/translations/validators.pl.xlf src/Symfony/Component/Validator/Resources/translations/validators.ru.xlf src/Symfony/Component/Validator/Resources/translations/validators.sl.xlf
Tobion
added a commit
that referenced
this pull request
Sep 9, 2015
…s (stof) This PR was merged into the 2.7 branch. Discussion ---------- Fix the injection of the container in invokable controllers | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | - | License | MIT | Doc PR | n/a #12022 added the necessary extension point in the ControllerResolver to hook into the instantiation (in 2.6+), but has not updated FrameworkBundle to use it. I also reused the parent ``createController`` method instead of duplicating its code Commits ------- 36e09da Fix the injection of the container in invokable controllers
ostrolucky
pushed a commit
to ostrolucky/symfony
that referenced
this pull request
Mar 25, 2018
* 2.6: (46 commits) fixxed order of usage [2.7] [Form] Replaced calls to array_search() by in_array() where is no need to get the index [Process] Make test AbstractProcessTest::testStartAfterATimeout useful again removed non-sense example Fixes small typo. [Validator] Remove unnecessary include in tests [HttpFoundation] minor: clarify Request::getUrlencodedPrefix() regex fixed typo [Validator] fix DOS-style line endings Drop useless execution bit bumped Symfony version to 2.6.5 [Serializer] update changelog updated VERSION for 2.6.4 updated CHANGELOG for 2.6.4 bumped Symfony version to 2.5.11 [HttpKernel] Added use of provided by symfony#12022 method to instantiate controller class in bundle's controller resolver updated VERSION for 2.5.10 updated CHANGELOG for 2.5.10 [Validator] Add a Russian translation for invalid charset message [2.3] [Validator] spanish translation for invalid charset message ... Conflicts: src/Symfony/Bridge/Doctrine/Validator/Constraints/UniqueEntityValidator.php src/Symfony/Component/HttpKernel/Exception/FatalErrorException.php src/Symfony/Component/HttpKernel/Exception/FlattenException.php src/Symfony/Component/HttpKernel/Kernel.php src/Symfony/Component/Routing/Tests/Generator/UrlGeneratorTest.php src/Symfony/Component/Validator/Resources/translations/validators.de.xlf src/Symfony/Component/Validator/Resources/translations/validators.en.xlf src/Symfony/Component/Validator/Resources/translations/validators.es.xlf src/Symfony/Component/Validator/Resources/translations/validators.fr.xlf src/Symfony/Component/Validator/Resources/translations/validators.pl.xlf src/Symfony/Component/Validator/Resources/translations/validators.ru.xlf src/Symfony/Component/Validator/Resources/translations/validators.sl.xlf
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Replaces #10814 to merge into
master
instead of2.3
.Currently it's required to duplicate the entirety of the
getController()
andcreateController()
methods just to replace the call tonew
(e.g. with container resolution, instead).Now it's possible to just override the
instantiateController()
method.