Conditions | 3 |
Paths | 3 |
Total Lines | 12 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 3.0175 |
Changes | 6 | ||
Bugs | 0 | Features | 1 |
1 | <?php namespace Cairns\Radiate; |
||
26 | 2 | public function emit($event) |
|
27 | { |
||
28 | 2 | foreach ($this->listeners as $listener) { |
|
29 | 2 | $method = $this->inflector->inflect($event, $listener); |
|
30 | |||
31 | 2 | if (! method_exists($listener, $method)) { |
|
32 | continue; |
||
33 | } |
||
34 | |||
35 | 2 | call_user_func_array([$listener, $method], func_get_args()); |
|
36 | 2 | } |
|
37 | 2 | } |
|
38 | } |
||
39 |