Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
4 / 4
100.00% covered (success)
100.00%
1 / 1
CRAP
n/a
0 / 0
dump
100.00% covered (success)
100.00%
4 / 4
100.00% covered (success)
100.00%
1 / 1
2
1<?php
2
3/**
4 * This file is always included and contains the dump() wrapper
5 */
6
7if (!function_exists('dump')) {
8    /**
9     * Dumps a variable
10     *
11     * @param mixed $variable The variable to dump.
12     *
13     * @return void
14     */
15    function dump($variable): void
16    {
17        $instance = \Miniframe\Toolbar\Service\DeveloperToolbar::getInstance();
18        if ($instance) {
19            $instance->dump($variable);
20        } else {
21            var_dump($variable);
22        }
23    }
24}