File tree Expand file tree Collapse file tree 2 files changed +8
-7
lines changed Expand file tree Collapse file tree 2 files changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -54,7 +54,7 @@ public function dump(Data $data)
54
54
55
55
$ trace = PHP_VERSION_ID >= 50306 ? DEBUG_BACKTRACE_PROVIDE_OBJECT | DEBUG_BACKTRACE_IGNORE_ARGS : true ;
56
56
if (PHP_VERSION_ID >= 50400 ) {
57
- $ trace = debug_backtrace ($ trace , 6 );
57
+ $ trace = debug_backtrace ($ trace , 7 );
58
58
} else {
59
59
$ trace = debug_backtrace ($ trace );
60
60
}
@@ -72,10 +72,11 @@ public function dump(Data $data)
72
72
$ file = $ trace [$ i ]['file ' ];
73
73
$ line = $ trace [$ i ]['line ' ];
74
74
75
- while (++$ i < 6 ) {
76
- if (isset ($ trace [$ i ]['function ' ]) && empty ($ trace [$ i ]['class ' ])) {
75
+ while (++$ i < 7 ) {
76
+ if (isset ($ trace [$ i ]['function ' ]) && empty ($ trace [$ i ]['class ' ]) && ' call_user_func ' !== $ trace [ $ i ][ ' function ' ] ) {
77
77
$ file = $ trace [$ i ]['file ' ];
78
78
$ line = $ trace [$ i ]['line ' ];
79
+
79
80
break ;
80
81
} elseif (isset ($ trace [$ i ]['object ' ]) && $ trace [$ i ]['object ' ] instanceof \Twig_Template) {
81
82
$ info = $ trace [$ i ]['object ' ];
Original file line number Diff line number Diff line change 11
11
12
12
namespace Symfony \Component \HttpKernel \EventListener ;
13
13
14
- use Symfony \Component \Debug \ Debug ;
14
+ use Symfony \Component \DependencyInjection \ ContainerInterface ;
15
15
use Symfony \Component \EventDispatcher \EventSubscriberInterface ;
16
16
use Symfony \Component \HttpKernel \KernelEvents ;
17
- use Symfony \Component \DependencyInjection \ ContainerInterface ;
17
+ use Symfony \Component \VarDumper \ VarDumper ;
18
18
19
19
/**
20
20
* Configures dump() handler.
@@ -43,11 +43,11 @@ public function configure()
43
43
$ dumper = $ this ->dumper ;
44
44
$ this ->container = null ;
45
45
46
- Debug:: setDumpHandler (function ($ var ) use ($ container , $ dumper ) {
46
+ VarDumper:: setHandler (function ($ var ) use ($ container , $ dumper ) {
47
47
$ dumper = $ container ->get ($ dumper );
48
48
$ cloner = $ container ->get ('var_dumper.cloner ' );
49
49
$ handler = function ($ var ) use ($ dumper , $ cloner ) {$ dumper ->dump ($ cloner ->cloneVar ($ var ));};
50
- Debug:: setDumpHandler ($ handler );
50
+ VarDumper:: setHandler ($ handler );
51
51
$ handler ($ var );
52
52
});
53
53
}
You can’t perform that action at this time.
0 commit comments