Conditions | 2 |
Paths | 2 |
Total Lines | 11 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
29 | public function sendData($data) |
||
30 | { |
||
31 | $response = $this->sendRequest($data, 'GET'); |
||
32 | $json = json_decode($response->getBody()->getContents(), true); |
||
33 | // if there's an event, retrieve the details, otherwise pass through the error |
||
34 | $notification = isset($json['events']) ? $json['events'] : $json; |
||
35 | |||
36 | $this->response = new WebhookEventNotification($this->httpClient, $this->httpRequest); |
||
|
|||
37 | $this->response->initialize(array_replace($this->getParameters(), ['notification' => $notification])); |
||
38 | |||
39 | return $this->response; |
||
40 | } |
||
42 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..