Skip to content

Commit e1c8de4

Browse files
Merge branch '4.4' into 5.1
* 4.4: minor cs fix [Config][TwigBundle] Fixed syntax error in config [DI] Fix Xdebug 3.0 detection Use php8 stable [Cache] fix checking for redis_sentinel support [Intl] Update the ICU data to 68.1 Remove unused @throws tags and handling of never thrown exceptions [PhpUnitBridge] Fix disabling DeprecationErrorHandler from phpunit configuration file
2 parents fc088b8 + e28b3dc commit e1c8de4

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
@@ -510,15 +510,7 @@ public function __clone()
510510
*/
511511
public function __toString()
512512
{
513-
try {
514-
$content = $this->getContent();
515-
} catch (\LogicException $e) {
516-
if (\PHP_VERSION_ID >= 70400) {
517-
throw $e;
518-
}
519-
520-
return trigger_error($e, \E_USER_ERROR);
521-
}
513+
$content = $this->getContent();
522514

523515
$cookieHeader = '';
524516
$cookies = [];
@@ -583,8 +575,6 @@ public function overrideGlobals()
583575
*
584576
* @param array $proxies A list of trusted proxies, the string 'REMOTE_ADDR' will be replaced with $_SERVER['REMOTE_ADDR']
585577
* @param int $trustedHeaderSet A bit field of Request::HEADER_*, to set which headers to trust from your proxies
586-
*
587-
* @throws \InvalidArgumentException When $trustedHeaderSet is invalid
588578
*/
589579
public static function setTrustedProxies(array $proxies, int $trustedHeaderSet)
590580
{
@@ -1506,8 +1496,6 @@ public function getProtocolVersion()
15061496
* @param bool $asResource If true, a resource will be returned
15071497
*
15081498
* @return string|resource The request body content or a resource to read the body stream
1509-
*
1510-
* @throws \LogicException
15111499
*/
15121500
public function getContent(bool $asResource = false)
15131501
{

0 commit comments

Comments
 (0)