| Conditions | 3 |
| Paths | 3 |
| Total Lines | 15 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 21 | public function getClassConfig($class, $excludeMiddleware, $next) |
||
| 22 | { |
||
| 23 | // Check if enabled |
||
| 24 | if (!$this->enabled($excludeMiddleware)) { |
||
| 25 | return $next($class, $excludeMiddleware); |
||
| 26 | } |
||
| 27 | |||
| 28 | // Merge hierarchy |
||
| 29 | $config = []; |
||
| 30 | foreach (ClassInfo::ancestry($class) as $nextClass) { |
||
| 31 | $nextConfig = $next($nextClass, $excludeMiddleware); |
||
| 32 | $config = Priority::mergeArray($nextConfig, $config); |
||
| 33 | } |
||
| 34 | return $config; |
||
| 35 | } |
||
| 36 | } |
||
| 37 |