Psr17Factory::createResponse( $code = 200,  $reasonPhrase = '' )

In this article

Source

public function createResponse(int $code = 200, string $reasonPhrase = ''): ResponseInterface
{
    if (2 > \func_num_args()) {
        // This will make the Response class to use a custom reasonPhrase
        $reasonPhrase = null;
    }
    return new Response($code, [], null, '1.1', $reasonPhrase);
}

User Contributed Notes

You must log in before being able to contribute a note or feedback.