| Conditions | 2 |
| Paths | 2 |
| Total Lines | 11 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 2 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php |
||
| 18 | public function run(\Closure $closure, array $parameters = []) |
||
| 19 | { |
||
| 20 | $cachableParameters = $this->convertToCachableParameters($parameters); |
||
| 21 | |||
| 22 | $cachekey = $this->baseKey.':'.md5(implode('', $cachableParameters)); |
||
| 23 | |||
| 24 | if (isset(static::$cache[$cachekey])) { |
||
| 25 | return static::$cache[$cachekey]; |
||
| 26 | } |
||
| 27 | |||
| 28 | return static::$cache[$cachekey] = call_user_func_array($closure, $parameters); |
||
| 29 | } |
||
| 45 |