Skip to content

Commit 33ed27f

Browse files
authored
Update request headers function for CLI and cron
1 parent 687b9a4 commit 33ed27f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

debug/debug-request-headers.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
function _core_debug_request_headers()
99
{
10-
if (!isset($_SERVER['REMOTE_ADDR'], $_SERVER['REQUEST_URI'])) {
10+
if (php_sapi_name() === 'cli' || wp_doing_cron() || !isset($_SERVER['REMOTE_ADDR'], $_SERVER['REQUEST_URI'])) {
1111
return;
1212
}
1313
$log_items = [

0 commit comments

Comments
 (0)