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

Appearance settings

[HttpFoundation] Added "null" type on Request::create docblock #25878

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

Closed
wants to merge 2 commits into from

Conversation

keradus
Copy link
Member

@keradus keradus commented Jan 21, 2018

Q A
Branch? 2.7
Bug fix? no
New feature? no
BC breaks? no
Deprecations? no
Tests pass? n/a
Fixed tickets n/a
License MIT
Doc PR n/a

Continuation of #24902 and #25875

@@ -130,7 +130,7 @@ class Request
public $headers;

/**
* @var string|resource
* @var null|string|resource
Copy link
Member Author

@keradus keradus Jan 21, 2018

Choose a reason for hiding this comment

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

actually, this could also be false, as we have false === $this->content several times

Copy link
Member

Choose a reason for hiding this comment

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

then add false?

Copy link
Member Author

Choose a reason for hiding this comment

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

at 1st glance i was wondering why it's false-able when it's already null-able...
looks like way too many types are allowed

* @param array $cookies The COOKIE parameters
* @param array $files The FILES parameters
* @param array $server The SERVER parameters
* @param null|string|resource $content The raw body data
Copy link
Member

Choose a reason for hiding this comment

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

please put null last, it's the less useful type to tell about (personally I don't even get its value at all: it's already on the signature, but anyway...)

Copy link
Member Author

Choose a reason for hiding this comment

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

arrays are also in the signatures you know ;)

@fabpot
Copy link
Member

fabpot commented Jan 29, 2018

Thank you @keradus.

fabpot added a commit that referenced this pull request Jan 29, 2018
…cblock (keradus)

This PR was squashed before being merged into the 2.7 branch (closes #25878).

Discussion
----------

[HttpFoundation] Added "null" type on Request::create docblock

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | n/a
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Continuation of #24902 and #25875

Commits
-------

b18f9e7 [HttpFoundation] Added "null" type on Request::create docblock
@fabpot fabpot closed this Jan 29, 2018
@keradus keradus deleted the 2.7_null branch January 29, 2018 09:23
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.

4 participants
Morty Proxy This is a proxified and sanitized view of the page, visit original site.