| Conditions | 1 |
| Paths | 1 |
| Total Lines | 13 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 1 |
| Changes | 0 | ||
| 1 | <?php |
||
| 24 | 8 | public function getDiff($source, $destination) |
|
| 25 | { |
||
| 26 | 8 | $this->ensureFileExists($source, $destination); |
|
| 27 | |||
| 28 | 7 | $destinationValues = $this->reader->read($destination); |
|
| 29 | 7 | $sourceValues = $this->reader->read($source); |
|
| 30 | |||
| 31 | 7 | $diffKeys = array_diff(array_keys($sourceValues), array_keys($destinationValues)); |
|
| 32 | |||
| 33 | 7 | return array_filter($sourceValues, function ($key) use ($diffKeys) { |
|
| 34 | 7 | return in_array($key, $diffKeys); |
|
| 35 | 7 | }, ARRAY_FILTER_USE_KEY); |
|
| 36 | } |
||
| 37 | |||
| 47 |