Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[HttpKernel] fix docblock#40611

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
Nyholm merged 1 commit intosymfony:5.2fromxabbuh:pr-40535
Mar 28, 2021
Merged

[HttpKernel] fix docblock#40611

Nyholm merged 1 commit intosymfony:5.2fromxabbuh:pr-40535
Mar 28, 2021

Conversation

@xabbuh
Copy link
Member

QA
Branch?5.2
Bug fix?no
New feature?no
Deprecations?no
Tickets
LicenseMIT
Doc PR

@xabbuhxabbuh added this to the5.2 milestoneMar 28, 2021
@xabbuhxabbuhforce-pushed thepr-40535 branch 2 times, most recently from5220f51 toda181fcCompareMarch 28, 2021 13:45
@xabbuhxabbuh changed the title[HttpKernel] debug test failures[HttpKernel] fix docblockMar 28, 2021
@xabbuh
Copy link
MemberAuthor

This fixes tests where the code is patched to have real return type declarations.

@Nyholm
Copy link
Member

I think you are referring to this PR#40535

But I dont see how your fix solves the build. Could you please elaborate?

* Returns true if the debug is enabled.
*
* @return bool true if debug is enabled, false otherwise
* @return bool|string true if debug is enabled, false otherwise or a string if no kernel was set
Copy link
Member

Choose a reason for hiding this comment

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

Is this better?

Suggested change
* @return bool|string trueif debug is enabled, false otherwiseor a stringif no kernel was set
* @return bool|'n/a' trueif debug is enabled, false otherwiseor a stringif no kernel was set

OskarStark reacted with heart emoji
Copy link
MemberAuthor

Choose a reason for hiding this comment

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

n/a is not a valid type I think

Copy link
Member

Choose a reason for hiding this comment

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

n/a is not a valid type I think

'n/a' is a literal type. PHPStan and Psalm support literal types, but I'm not aware that we've ever used them in the Symfony codebase.

@xabbuh
Copy link
MemberAuthor

@Nyholm In the pipeline we have a job that patches our code to add real return type declarations. Which means here that whenn/a is cast to a booleanisDebug() always returnstrue.

@Nyholm
Copy link
Member

Oh. That is cool. I didn't know that.

@Nyholm
Copy link
Member

Thank you

@NyholmNyholm merged commit5545755 intosymfony:5.2Mar 28, 2021
@xabbuhxabbuh deleted the pr-40535 branchMarch 28, 2021 18:57
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@NyholmNyholmNyholm left review comments

@derrabusderrabusderrabus left review comments

@wouterjwouterjwouterj approved these changes

@OskarStarkOskarStarkOskarStark approved these changes

Assignees

No one assigned

Projects

None yet

Milestone

5.2

Development

Successfully merging this pull request may close these issues.

6 participants

@xabbuh@Nyholm@wouterj@OskarStark@derrabus@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp