| 1 | <?php |
||
| 18 | class Client |
||
| 19 | { |
||
| 20 | /** |
||
| 21 | * @var HttpClient |
||
| 22 | */ |
||
| 23 | private $client; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * @var Headers |
||
| 27 | */ |
||
| 28 | private $headers; |
||
| 29 | |||
| 30 | /** |
||
| 31 | * @param ClientInterface $client |
||
| 32 | */ |
||
| 33 | 15 | public function __construct(ClientInterface $client = null) |
|
| 38 | |||
| 39 | /** |
||
| 40 | * @param string $key |
||
| 41 | * @param string $value |
||
| 42 | * |
||
| 43 | * @return $this |
||
| 44 | */ |
||
| 45 | 1 | public function addHeader($key, $value) |
|
| 51 | |||
| 52 | /** |
||
| 53 | * @param string $url |
||
| 54 | * @param string $body |
||
| 55 | * @throws SiftScienceRequestException |
||
| 56 | * |
||
| 57 | * @return ResponseInterface |
||
| 58 | */ |
||
| 59 | 8 | public function post($url, $body) |
|
| 74 | } |
||
| 75 |
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 given class or a super-class is assigned to a property that is type hinted more strictly.
Either this assignment is in error or an instanceof check should be added for that assignment.