Skip to content

Update console.rst #19191

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
Dec 9, 2023
Merged

Update console.rst #19191

merged 1 commit into from
Dec 9, 2023

Conversation

hbgamra
Copy link
Contributor

@hbgamra hbgamra commented Nov 28, 2023

remove $kernel variable

@javiereguiluz
Copy link
Member

In the Symfony Demo app we recently had to do this change to fix some PHPStan issue: symfony/demo@b9b47c7

self::bootKernel();
$application = new Application(self::$kernel);
Copy link
Contributor

Choose a reason for hiding this comment

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

maybe we could go a step further?

Suggested change
self::bootKernel();
$application = new Application(self::$kernel);
$application = new Application(self::bootKernel());

@theofidry
Copy link
Contributor

I am not sure we should worry about PHPStan here however, the variable type is documented correctly and PHPStan does not come with Symfony by default.

@OskarStark OskarStark added this to the 5.4 milestone Dec 9, 2023
remove $kernel variable
@OskarStark OskarStark changed the base branch from 6.3 to 5.4 December 9, 2023 08:57
@OskarStark
Copy link
Contributor

Thank you @hbgamra.

@OskarStark OskarStark merged commit a8d437e into symfony:5.4 Dec 9, 2023
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.

6 participants