| Conditions | 3 |
| Paths | 3 |
| Total Lines | 13 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 2 |
| CRAP Score | 7.2349 |
| Changes | 0 | ||
| 1 | <?php |
||
| 26 | public function calculateRoundTripRelations() |
||
| 27 | { |
||
| 28 | 1 | $modelNames = $this->getCandidateModels(); |
|
| 29 | 1 | ||
| 30 | foreach ($modelNames as $name) { |
||
| 31 | if (!$this->getRelationHolder()->hasClass($name)) { |
||
| 32 | $model = new $name(); |
||
| 33 | $this->getRelationHolder()->addModel($model); |
||
| 34 | } |
||
| 35 | } |
||
| 36 | |||
| 37 | return $this->getRelationHolder()->getRelations(); |
||
| 38 | } |
||
| 39 | } |
||
| 40 |