Skip to content

Commit

Permalink
minor #5128 [VarDumper] little optim (lyrixx)
Browse files Browse the repository at this point in the history
This PR was submitted for the 2.7 branch but it was merged into the 2.6 branch instead (closes #5128).

Discussion
----------

[VarDumper] little optim

| Q             | A
| ------------- | ---
| Doc fix?      | no
| New docs?     | no
| Applies to    | 2.7+
| Fixed tickets | -

related to symfony/symfony#14137
and asked by @nicolas-grekas

Commits
-------

a880fe4 [VarDumper] little optim
  • Loading branch information
wouterj committed Apr 2, 2015
2 parents 5880f38 + a880fe4 commit 1d443c0
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions components/var_dumper/advanced.rst
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,7 @@ Another option for doing the same could be::
$output = fopen('php://memory', 'r+b');

$dumper->dump($cloner->cloneVar($variable), $output);
rewind($output);
$output = stream_get_contents($output);
$output = stream_get_contents($output, -1, 0);

// $output is now populated with the dump representation of $variable

Expand Down

0 comments on commit 1d443c0

Please sign in to comment.