| Conditions | 2 |
| Paths | 1 |
| Total Lines | 12 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 26 | public function create($metaable, $meta, $group) |
||
| 27 | { |
||
| 28 | return $this->getModel() |
||
| 29 | ->create([ |
||
| 30 | 'metaable_id' => $metaable->id, |
||
| 31 | 'metaable_type' => get_class($metaable), |
||
| 32 | 'key' => $meta['key'], |
||
| 33 | 'value' => $meta['value'], |
||
| 34 | 'group' => (! is_null($group)) ? $group : 'other', |
||
| 35 | 'key_unique' => $meta['key_unique'] |
||
| 36 | ]); |
||
| 37 | } |
||
| 38 | |||
| 78 | } |
If you implement
__calland you know which methods are available, you can improve IDE auto-completion and static analysis by adding a @method annotation to the class.This is often the case, when
__callis implemented by a parent class and only the child class knows which methods exist: