File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed
Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change 5454 && isset ($ _SERVER ['HTTP_ACCEPT ' ])
5555 && strpos ($ _SERVER ['HTTP_ACCEPT ' ], 'text/html ' ) !== false
5656) {
57- \Magento \Framework \Profiler::applyConfig (
58- (isset ($ _SERVER ['MAGE_PROFILER ' ]) && strlen ($ _SERVER ['MAGE_PROFILER ' ])) ? $ _SERVER ['MAGE_PROFILER ' ] : trim (file_get_contents (BP . '/var/profiler.flag ' )),
57+ $ profilerConfig = isset ($ _SERVER ['MAGE_PROFILER ' ]) && strlen ($ _SERVER ['MAGE_PROFILER ' ])
58+ ? $ _SERVER ['MAGE_PROFILER ' ]
59+ : trim (file_get_contents (BP . '/var/profiler.flag ' ));
60+
61+ if ($ profilerConfig ) {
62+ $ profilerConfig = json_decode ($ profilerConfig , true ) ?: $ profilerConfig ;
63+ }
64+
65+ Magento \Framework \Profiler::applyConfig (
66+ $ profilerConfig ,
5967 BP ,
6068 !empty ($ _SERVER ['HTTP_X_REQUESTED_WITH ' ]) && $ _SERVER ['HTTP_X_REQUESTED_WITH ' ] == 'XMLHttpRequest '
6169 );
You can’t perform that action at this time.
0 commit comments