8000 [2.2] sub-requests are now created with the same class as their parent by jfsimon · Pull Request #7390 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[2.2] sub-requests are now created with the same class as their parent #7390

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
merged 1 commit into from
Mar 18, 2013

Conversation

jfsimon
Copy link
Contributor
@jfsimon jfsimon commented Mar 15, 2013

Following #7381

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #7185, #7186

@@ -89,7 +89,7 @@ protected function createSubRequest($uri, Request $request)
// the sub-request is internal
$server['REMOTE_ADDR'] = '127.0.0.1';

$subRequest = Request::create($uri, 'get', array(), $cookies, array(), $server);
$subRequest = $request::create($uri, 'get', array(), $cookies, array(), $server);
Copy link
Contributor

Choose a reason for hiding this comment

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

Does it make sense to invoke static methods on objects?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I know it's weird, but it makes sense.
See comments in #7381.

fabpot added a commit that referenced this pull request Mar 18, 2013
This PR was merged into the 2.2 branch.

Commits
-------

53cf12b replaced new occurences of 'Request::create()' with '::create()'

Discussion
----------

[2.2] sub-requests are now created with the same class as their parent

Following #7381

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #7185, #7186
@fabpot fabpot merged commit 53cf12b into symfony:2.2 Mar 18, 2013
fabpot added a commit that referenced this pull request Oct 1, 2013
…ss (fabpot)

This PR was merged into the master branch.

Discussion
----------

[HttpFoundation] added a way to override the Request class

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #7461, #7453
| License       | MIT
| Doc PR        | symfony/symfony-docs#3021

This is an alternative implementation for #7461.

I've also reverted #7381 and #7390 as these changes are not needed anymore.

Todo:

 - [ ] add some tests

Commits
-------

464439d [HttpFoundation] added a way to override the Request class
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0