We have detected an error in your notification set-up
(Event-ID dab39dc24f564ec7bd4628d1305fd03c).
Currently, we cannot inform you about inspection progress.
Please check that the user
557058:bca11929-8c2d-43f2-8a82-c5416880d395
still has access to your repository or
update the API account.
1 | <?php |
||
25 | class ApiOneCollectionListener implements ListenerInterface |
||
26 | { |
||
27 | /** @var array */ |
||
28 | private $urlComponents; |
||
29 | |||
30 | /** @var string */ |
||
31 | private $resource; |
||
32 | |||
33 | /** |
||
34 | * {@inheritDoc} |
||
35 | */ |
||
36 | 283 | public function getName() |
|
40 | |||
41 | /** |
||
42 | * {@inheritDoc} |
||
43 | * @codeCoverageIgnore |
||
44 | */ |
||
45 | public function preSend(RequestInterface $request) |
||
48 | |||
49 | /** |
||
50 | * {@inheritDoc} |
||
51 | */ |
||
52 | 8 | public function postSend(RequestInterface $request, MessageInterface $response) |
|
67 | |||
68 | /** |
||
69 | * @access public |
||
70 | * @param MessageInterface $request |
||
71 | * @return bool |
||
72 | */ |
||
73 | 8 | private function isLegacyApiVersion(MessageInterface $request) |
|
78 | |||
79 | /** |
||
80 | * @access public |
||
81 | * @param RequestInterface $request |
||
82 | * @return void |
||
83 | */ |
||
84 | 6 | private function parseRequest(RequestInterface $request) |
|
107 | |||
108 | /** |
||
109 | * @access public |
||
110 | * @param MessageInterface $response |
||
111 | * @return bool |
||
112 | */ |
||
113 | 6 | private function canPaginate(MessageInterface $response) |
|
118 | |||
119 | /** |
||
120 | * @access private |
||
121 | * @param MessageInterface $response |
||
122 | * @return array |
||
123 | */ |
||
124 | 6 | private function getContent(MessageInterface $response) |
|
134 | |||
135 | /** |
||
136 | * @access private |
||
137 | * @param array $content |
||
138 | * @param array $pagination |
||
139 | * @return array |
||
140 | */ |
||
141 | 2 | private function insertPaginationMeta(array $content, array $pagination) |
|
179 | |||
180 | /** |
||
181 | * @access private |
||
182 | * @param MessageInterface $response |
||
183 | * @return array |
||
184 | */ |
||
185 | 2 | private function getPaginationMeta(MessageInterface $response) |
|
203 | } |
||
204 |
Our type inference engine has found a suspicous assignment of a value to a property. This check raises an issue when a value that can be of a mixed type is assigned to a property that is type hinted more strictly.
For example, imagine you have a variable
$accountId
that can either hold an Id object or false (if there is no account id yet). Your code now assigns that value to theid
property of an instance of theAccount
class. This class holds a proper account, so the id value must no longer be false.Either this assignment is in error or a type check should be added for that assignment.