| Conditions | 5 | 
| Paths | 4 | 
| Total Lines | 15 | 
| Code Lines | 10 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Changes | 1 | ||
| Bugs | 0 | Features | 1 | 
| 1 | <?php | ||
| 40 | public function invoke(): \Generator | ||
| 41 |     { | ||
| 42 |         while ($this->current_retry_count <= $this->max_retry or $this->max_retry === -1) { | ||
| 43 |             try { | ||
| 44 | yield from $this->chain->invoke(); | ||
| 45 |             } catch (Exception $e) { | ||
| 46 |                 if (in_array(get_class($e), $this->exception_names, true)) { | ||
| 47 | $this->current_retry_count++; | ||
| 48 | continue; | ||
| 49 | } | ||
| 50 | throw $e; | ||
| 51 | } | ||
| 52 | $this->current_retry_count = 0; | ||
| 53 | } | ||
| 54 | return false; | ||
| 55 | } | ||
| 57 |