Skip to content

Commit

Permalink
[HttpFoundation] Remove invalid HTTP method from exception message
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolas-grekas committed Oct 25, 2024
1 parent 3f38426 commit 38bd9bc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Request.php
Original file line number Diff line number Diff line change
Expand Up @@ -1294,7 +1294,7 @@ public function getMethod()
}

if (!preg_match('/^[A-Z]++$/D', $method)) {
throw new SuspiciousOperationException(sprintf('Invalid method override "%s".', $method));
throw new SuspiciousOperationException('Invalid HTTP method override.');
}

return $this->method = $method;
Expand Down

0 comments on commit 38bd9bc

Please sign in to comment.