Skip to content

[make:crud] render or renderForm - Avoid deprecations in 6.2 #1272

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 6 commits into from
May 23, 2023

Conversation

nacorp
Copy link
Contributor

@nacorp nacorp commented Jan 13, 2023

The old use_render_form is always true, in both Symfony 5.4 and 6.2 so we always end un with a $this->renderForm() that has been deprecated in 6.2.

This (ugly, but nevertheless working) hack tests if getDoctrine exists in AbstractController allows us to determine Symfony's version and if we should generate a $this->render() or a $this->renderForm().

@nacorp nacorp changed the title Avoid generating deprecated $this->renderForm() in 6.2 [make:crud] render or renderForm - Avoid depreciations in 6.2 Jan 13, 2023
@OskarStark OskarStark changed the title [make:crud] render or renderForm - Avoid depreciations in 6.2 [make:crud] render or renderForm - Avoid deprecations in 6.2 Jan 15, 2023
@jrushlow jrushlow force-pushed the make-crud-depreciation-renderform branch from acd5afb to c181d10 Compare May 23, 2023 12:51
@jrushlow jrushlow added the Feature New Feature label May 23, 2023
Copy link
Collaborator

@jrushlow jrushlow left a comment

Choose a reason for hiding this comment

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

Thank you @nacorp for the PR! It's greatly appreciated...

@jrushlow jrushlow added Status: Reviewed Has been reviewed by a maintainer Related Tests Pass labels May 23, 2023
@jrushlow jrushlow merged commit b1e6940 into symfony:main May 23, 2023
weaverryan added a commit that referenced this pull request Jun 11, 2023
This PR was merged into the 1.0-dev branch.

Discussion
----------

[make:crud] fix typo in Kernel::VERSION usage

The recently merged pr #1272 did not correct the use_render_form because of a typo in the Kernel Version Id

Commits
-------

b056cd2 fix:  Kernel::VERSION is wrong for Symfony 6.2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature New Feature Related Tests Pass Status: Reviewed Has been reviewed by a maintainer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants