mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-03 09:49:28 +02:00
Add check for empty REQUEST_METHOD in stopHeadRequests condition
This commit is contained in:
parent
4e452049bc
commit
f27a036e70
1 changed files with 1 additions and 1 deletions
|
@ -6,7 +6,7 @@ if (!isset($global['skippPlugins'])) {
|
|||
|
||||
|
||||
if (!empty($global['stopHeadRequests'])) {
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'HEAD') {
|
||||
if (!empty($_SERVER['REQUEST_METHOD']) && $_SERVER['REQUEST_METHOD'] === 'HEAD') {
|
||||
// Optionally, you can send a specific status code or header before exiting
|
||||
http_response_code(200); // Set response code if needed
|
||||
error_log('stopIfIsHeadRequest '.$_SERVER['HTTP_USER_AGENT']);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue