Skip to content

Commit b313c78

Browse files
committed
Merge branch '4.1'
* 4.1: [VarDumper] Add missing use statements
2 parents 48e8872 + 0ecba9a commit b313c78

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

components/var_dumper.rst

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -165,14 +165,18 @@ Outside a Symfony application, use the :class:`Symfony\\Component\\VarDumper\\Du
165165

166166
use Symfony\Component\VarDumper\VarDumper;
167167
use Symfony\Component\VarDumper\Cloner\VarCloner;
168+
use Symfony\Component\VarDumper\Dumper\CliDumper;
169+
use Symfony\Component\VarDumper\Dumper\ContextProvider\CliContextProvider;
170+
use Symfony\Component\VarDumper\Dumper\ContextProvider\SourceContextProvider;
171+
use Symfony\Component\VarDumper\Dumper\HtmlDumper;
168172
use Symfony\Component\VarDumper\Dumper\ServerDumper;
169173

170174
$cloner = new VarCloner();
171175
$fallbackDumper = \in_array(\PHP_SAPI, array('cli', 'phpdbg')) ? new CliDumper() : new HtmlDumper();
172-
$dumper = new ServerDumper('tcp://127.0.0.1:9912', $fallbackDumper, [
176+
$dumper = new ServerDumper('tcp://127.0.0.1:9912', $fallbackDumper, array(
173177
'cli' => new CliContextProvider(),
174178
'source' => new SourceContextProvider(),
175-
]);
179+
));
176180

177181
VarDumper::setHandler(function ($var) use ($cloner, $dumper) {
178182
$dumper->dump($cloner->cloneVar($var));
@@ -184,7 +188,7 @@ Outside a Symfony application, use the :class:`Symfony\\Component\\VarDumper\\Du
184188
is a :class:`Symfony\\Component\\VarDumper\\Dumper\\DataDumperInterface` instance
185189
used as a fallback when the server is unreachable. The third argument are the
186190
context providers, which allow to gather some info about the context in which the
187-
data was dumped. The built-in contexts providers are: ``cli``, ``request`` and ``source``.
191+
data was dumped. The built-in context providers are: ``cli``, ``request`` and ``source``.
188192

189193
Then you can use the following command to start a server out-of-the-box:
190194

0 commit comments

Comments
 (0)