1 | <?php |
||
2 | |||
3 | declare(strict_types=1); |
||
4 | |||
5 | namespace BEAR\Resource; |
||
6 | |||
7 | use Override; |
||
8 | |||
9 | /** @psalm-import-type Query from Types */ |
||
10 | final class NullRequest implements RequestInterface |
||
11 | { |
||
12 | /** @param Query $query */ |
||
0 ignored issues
–
show
|
|||
13 | #[Override] |
||
14 | public function __invoke(array|null $query = null): ResourceObject |
||
15 | 7 | { |
|
16 | return new NullResourceObject(); |
||
17 | 7 | } |
|
18 | 7 | ||
19 | #[Override] |
||
20 | 1 | public function hash(): string |
|
21 | { |
||
22 | 1 | return ''; |
|
23 | } |
||
24 | |||
25 | 1 | #[Override] |
|
26 | public function request(): ResourceObject |
||
27 | 1 | { |
|
28 | return new NullResourceObject(); |
||
29 | } |
||
30 | 1 | ||
31 | /** |
||
32 | 1 | * {@inheritDoc} |
|
33 | */ |
||
34 | #[Override] |
||
35 | 1 | public function withQuery(array $query): RequestInterface |
|
36 | { |
||
37 | 1 | unset($query); |
|
38 | |||
39 | return $this; |
||
40 | 1 | } |
|
41 | |||
42 | 1 | /** |
|
43 | * {@inheritDoc} |
||
44 | */ |
||
45 | 1 | #[Override] |
|
46 | public function addQuery(array $query): RequestInterface |
||
47 | 1 | { |
|
48 | unset($query); |
||
49 | |||
50 | 1 | return $this; |
|
51 | } |
||
52 | 1 | ||
53 | #[Override] |
||
54 | public function toUri(): string |
||
55 | { |
||
56 | return (string) new NullUri(); |
||
57 | } |
||
58 | |||
59 | #[Override] |
||
60 | public function toUriWithMethod(): string |
||
61 | { |
||
62 | return 'get ' . (string) new NullUri(); |
||
63 | } |
||
64 | |||
65 | /** @return self */ |
||
66 | #[Override] |
||
67 | public function linkSelf(string $linkKey): RequestInterface |
||
68 | { |
||
69 | unset($linkKey); |
||
70 | |||
71 | return $this; |
||
72 | } |
||
73 | |||
74 | /** @return self */ |
||
75 | #[Override] |
||
76 | public function linkNew(string $linkKey): RequestInterface |
||
77 | { |
||
78 | unset($linkKey); |
||
79 | |||
80 | return $this; |
||
81 | } |
||
82 | |||
83 | /** @return self */ |
||
84 | #[Override] |
||
85 | public function linkCrawl(string $linkKey): RequestInterface |
||
86 | { |
||
87 | unset($linkKey); |
||
88 | |||
89 | return $this; |
||
90 | } |
||
91 | } |
||
92 |
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:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths