Passed
Push — master ( 035a69...ef3bdc )
by Kirill
03:22
created

UriFactory::createUri()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 1
c 1
b 0
f 0
dl 0
loc 3
rs 10
cc 1
nc 1
nop 1
1
<?php
2
3
/**
4
 * Spiral Framework.
5
 *
6
 * @license   MIT
7
 * @author    Anton Titov (Wolfy-J)
8
 */
9
10
declare(strict_types=1);
11
12
namespace Spiral\Tests\Router\Diactoros;
13
14
use Psr\Http\Message\UriFactoryInterface;
15
use Psr\Http\Message\UriInterface;
16
use Laminas\Diactoros\Uri;
17
18
final class UriFactory implements UriFactoryInterface
19
{
20
    /**
21
     * @param string $uri
22
     * @return UriInterface
23
     */
24
    public function createUri(string $uri = ''): UriInterface
25
    {
26
        return new Uri($uri);
27
    }
28
}
29