Skip to content

Commit 2874fb1

Browse files
committed
refactor: apply EmptyOnNullableObjectToInstanceOfRector
1 parent 145415e commit 2874fb1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

system/HTTP/IncomingRequest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ class IncomingRequest extends Request
152152
*/
153153
public function __construct($config, ?URI $uri = null, $body = 'php://input', ?UserAgent $userAgent = null)
154154
{
155-
if (empty($uri) || empty($userAgent)) {
155+
if (! $uri instanceof URI || ! $userAgent instanceof UserAgent) {
156156
throw new InvalidArgumentException('You must supply the parameters: uri, userAgent.');
157157
}
158158

0 commit comments

Comments
 (0)