mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-03 22:32:40 +08:00
Removed Response::removeOutput, moved recursive buffer cleanup into Response::cleanOutput
This commit is contained in:
@ -40,19 +40,11 @@ class Response extends Component
|
|||||||
return ob_get_contents();
|
return ob_get_contents();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Discards the output buffer
|
|
||||||
*/
|
|
||||||
public function cleanOutput()
|
|
||||||
{
|
|
||||||
ob_clean();
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Discards the output buffer
|
* Discards the output buffer
|
||||||
* @param boolean $all if true recursively discards all output buffers used
|
* @param boolean $all if true recursively discards all output buffers used
|
||||||
*/
|
*/
|
||||||
public function removeOutput($all = true)
|
public function cleanOutput($all = true)
|
||||||
{
|
{
|
||||||
if ($all) {
|
if ($all) {
|
||||||
for ($level = ob_get_level(); $level > 0; --$level) {
|
for ($level = ob_get_level(); $level > 0; --$level) {
|
||||||
|
|||||||
Reference in New Issue
Block a user