| Conditions | 2 |
| Paths | 2 |
| Total Lines | 8 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 2 |
| CRAP Score | 2 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 29 | public function __invoke(LogRecord $record): LogRecord |
||
| 30 | { |
||
| 31 | $value = get_in($record->toArray(), $this->from); |
||
| 32 | if ($value !== null) { |
||
| 33 | $record = $record->with(...array_merge_recursive(assoc_in([], $this->to, $value), ['context' => $record->context, 'extra' => $record->extra])); |
||
| 34 | 3 | } |
|
| 35 | |||
| 36 | 3 | return $record; |
|
| 37 | 3 | } |
|
| 39 |