| Conditions | 2 |
| Paths | 2 |
| Total Lines | 13 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 1 | Features | 1 |
| 1 | <?php |
||
| 21 | public function get($issueIdOrKey, $paramArray = []): ?AgileIssue |
||
| 22 | { |
||
| 23 | $response = $this->exec($this->uri.'/'.$issueIdOrKey.$this->toHttpQueryParameter($paramArray), null); |
||
| 24 | |||
| 25 | try { |
||
| 26 | return $this->json_mapper->map( |
||
| 27 | json_decode($response, false, 512, JSON_THROW_ON_ERROR), |
||
| 28 | new AgileIssue() |
||
| 29 | ); |
||
| 30 | } catch (\JsonException $exception) { |
||
| 31 | $this->log->error("Response cannot be decoded from json\nException: {$exception->getMessage()}"); |
||
| 32 | |||
| 33 | return null; |
||
| 34 | } |
||
| 37 |