Passed
Push — master ( 044d11...9c3395 )
by Mr.
01:48
created

src/SvgViewInjection.php (2 issues)

Labels
Severity
1
<?php
2
3
declare(strict_types=1);
4
5
namespace YiiRocks\SvgInline;
6
7
use Yiisoft\Yii\View\ContentParametersInjectionInterface;
0 ignored issues
show
The type Yiisoft\Yii\View\Content...etersInjectionInterface was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
8
use Yiisoft\Yii\View\LayoutParametersInjectionInterface;
0 ignored issues
show
The type Yiisoft\Yii\View\LayoutP...etersInjectionInterface was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
9
10
final class SvgViewInjection implements ContentParametersInjectionInterface, LayoutParametersInjectionInterface
11
{
12
    private SvgInlineInterface $svg;
13
14
    public function __construct(
15
        SvgInlineInterface $svg
16
    ) {
17
        $this->svg = $svg;
18
    }
19
20
    public function getContentParameters(): array
21
    {
22
        return [
23
            'svg' => $this->svg,
24
        ];
25
    }
26
27
    public function getLayoutParameters(): array
28
    {
29
        return [
30
            'svg' => $this->svg,
31
        ];
32
    }
33
}
34