Create New Item
Item Type
File
Folder
Item Name
Search file in folder and subfolders...
Are you sure want to rename?
optometrists
/
cache
/
cache
/
cache
/
cache
/
cache
/
cache
/
cache
/
.wp-cli
/
wp-content
/
plugins
/
wp-phpmyadmin-extension
/
lib
/
phpMyAdmin
/
vendor
/
slim
/
psr7
/
src
/
Factory
:
ResponseFactory.php
Advanced Search
Upload
New Item
Settings
Back
Back Up
Advanced Editor
Save
<?php /** * Slim Framework (https://slimframework.com) * * @license https://github.com/slimphp/Slim-Psr7/blob/master/LICENSE.md (MIT License) */ declare(strict_types=1); namespace Slim\Psr7\Factory; use Fig\Http\Message\StatusCodeInterface; use Psr\Http\Message\ResponseFactoryInterface; use Psr\Http\Message\ResponseInterface; use Slim\Psr7\Response; class ResponseFactory implements ResponseFactoryInterface { /** * {@inheritdoc} */ public function createResponse( int $code = StatusCodeInterface::STATUS_OK, string $reasonPhrase = '' ): ResponseInterface { $res = new Response($code); if ($reasonPhrase !== '') { $res = $res->withStatus($code, $reasonPhrase); } return $res; } }