| Conditions | 6 |
| Paths | 5 |
| Total Lines | 15 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 42 |
| Changes | 0 | ||
| 1 | <?php |
||
| 49 | public function forgetAbout($models, $event = null) |
||
| 50 | { |
||
| 51 | foreach ($models as $model) { |
||
| 52 | |||
| 53 | foreach ($this->data as $i => $data) { |
||
| 54 | |||
| 55 | if (($key = array_search($model, $data[0])) === false) { |
||
| 56 | continue; |
||
| 57 | } |
||
| 58 | |||
| 59 | if (! is_null($event) && $event !== $data[1]) { |
||
| 60 | continue; |
||
| 61 | } |
||
| 62 | |||
| 63 | unset($this->data[$i][0][$key]); |
||
| 64 | } |
||
| 68 |