| Conditions | 3 |
| Paths | 3 |
| Total Lines | 15 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | public function output(Collection $detectedQueries, Response $response) |
||
| 17 | { |
||
| 18 | LaravelLog::info('Detected N+1 Query'); |
||
| 19 | foreach ($detectedQueries as $detectedQuery) { |
||
| 20 | LaravelLog::info('Model: '.$detectedQuery['model']); |
||
| 21 | LaravelLog::info('Relation: '.$detectedQuery['relation']); |
||
| 22 | LaravelLog::info('Num-Called: '.$detectedQuery['count']); |
||
| 23 | |||
| 24 | LaravelLog::info('Call-Stack:'); |
||
| 25 | |||
| 26 | foreach ($detectedQuery['sources'] as $source) { |
||
| 27 | LaravelLog::info('#'.$source->index.' '.$source->name.':'.$source->line); |
||
| 28 | } |
||
| 29 | } |
||
| 30 | } |
||
| 31 | } |
||
| 32 |