Skip to content

Commit 6528d37

Browse files
Merge branch '5.1' into 5.2
* 5.1: minor cs fix [Config][TwigBundle] Fixed syntax error in config [DI] Fix Xdebug 3.0 detection Use php8 stable [Notifier] Streamline changelogs of notifier bridges [Cache] fix checking for redis_sentinel support [Messenger] Fixed wording in php doc [Intl] Update the ICU data to 68.1 [FrameworkBundle] acces public-deprecated services via the private container to remove false-positive deprecations Remove unused @throws tags and handling of never thrown exceptions [PhpUnitBridge] Fix disabling DeprecationErrorHandler from phpunit configuration file
2 parents aa8f7b7 + e1c8de4 commit 6528d37

File tree

2 files changed

+1
-15
lines changed

2 files changed

+1
-15
lines changed

JsonResponse.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,6 @@ public function setCallback(string $callback = null)
135135
* Sets a raw string containing a JSON document to be sent.
136136
*
137137
* @return $this
138-
*
139-
* @throws \InvalidArgumentException
140138
*/
141139
public function setJson(string $json)
142140
{

Request.php

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -516,15 +516,7 @@ public function __clone()
516516
*/
517517
public function __toString()
518518
{
519-
try {
520-
$content = $this->getContent();
521-
} catch (\LogicException $e) {
522-
if (\PHP_VERSION_ID >= 70400) {
523-
throw $e;
524-
}
525-
526-
return trigger_error($e, \E_USER_ERROR);
527-
}
519+
$content = $this->getContent();
528520

529521
$cookieHeader = '';
530522
$cookies = [];
@@ -589,8 +581,6 @@ public function overrideGlobals()
589581
*
590582
* @param array $proxies A list of trusted proxies, the string 'REMOTE_ADDR' will be replaced with $_SERVER['REMOTE_ADDR']
591583
* @param int $trustedHeaderSet A bit field of Request::HEADER_*, to set which headers to trust from your proxies
592-
*
593-
* @throws \InvalidArgumentException When $trustedHeaderSet is invalid
594584
*/
595585
public static function setTrustedProxies(array $proxies, int $trustedHeaderSet)
596586
{
@@ -1533,8 +1523,6 @@ public function getProtocolVersion()
15331523
* @param bool $asResource If true, a resource will be returned
15341524
*
15351525
* @return string|resource The request body content or a resource to read the body stream
1536-
*
1537-
* @throws \LogicException
15381526
*/
15391527
public function getContent(bool $asResource = false)
15401528
{

0 commit comments

Comments
 (0)