-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[FrameworkBundle] Upgrade notice for the Controller::json() method #18373
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
Conversation
Since I haven't changed any code, I'd guess the CI build fails are unrelated to my change. |
@@ -24,6 +24,10 @@ FrameworkBundle | |||
|
|||
* As it was never an officially supported feature, the support for absolute | |||
template paths has been deprecated and will be removed in Symfony 4.0. | |||
* The abstract `Controller` class now has a `json()` helper method that creates |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing empty line :)
On second thought, if the method is overridden everything should work fine, doesn't it ? |
@HeahDude: If the signatures of the methods don't match, php will throw a fatal error. |
I don't think many people will run into this. Nevertheless, I think it's worth documenting. |
Of courses! ping @dunglas |
I see a warning about signature mismatch, but not a fatal error, just did a little check
|
@mcfedr PHP version ? |
|
I am use php 7, I also see the Strict warning on php 5 |
Either way, its probably worth noting in the UPDATE log |
👍 |
As this is not part of the symfony BC policy, I'm not sure this should be specified in the upgrade file. Maybe only in the changelog? |
We didn't do that in the past when introducing more helper methods in Symfony 2.8. On the other hand it doesn't really hurt to add this and having a |
I've added the extra blank line as requested by @HeahDude and rebased against master to resolve conflicts. |
Thank you @derrabus. |
…n() method (derrabus) This PR was merged into the 3.1-dev branch. Discussion ---------- [FrameworkBundle] Upgrade notice for the Controller::json() method | Q | A | ------------- | --- | Branch? | master | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | N/A | License | MIT | Doc PR | N/A PR #17642 added a `json()` method to the `Controller` class. This might break existing code extending the class. This PR adds a note about this to the UPGRADE-3.1 document. Commits ------- ca6694a Upgrade notice for the Controller::json() method.
PR #17642 added a
json()
method to theController
class. This might break existing code extending the class. This PR adds a note about this to the UPGRADE-3.1 document.