symfony/symfony — pull request #5864 by niklasf (2012-10-29 12:33:08+00:00)
Title: [HttpFoundation] Return value of BinaryFileResponse::getContent() and StreamedResponse::getContent()

While reviewing #4546 @stof found an inconsistency:

```php
public function setContent($content)
{
if (null !== $content) { // <--- Here we only alow null
throw new \LogicException('The content cannot be set on a StreamedResponse instance.');
}
}
```

```php
public function getContent()
{
return false; // <-- Here we return false
}
```

That means for example, that `$streamedResponse->setContent($streamedResponse->getContent())` will throw an exception.

Should we (or can we even, without breaking backwards compability) change the return value of StreamedResponse::getContent() and BinaryFileResponse::getContent() to `null`?