| Conditions | 2 |
| Paths | 2 |
| Total Lines | 13 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 6 |
| Changes | 0 | ||
| 1 | <?php |
||
| 19 | public function __call($name, $arguments) |
||
| 20 | { |
||
| 21 | $action = substr($name, 0, 3); |
||
| 22 | |||
| 23 | if ($action === 'set') { |
||
| 24 | $property = Str::snake(substr($name, 3)); |
||
| 25 | $this->put($property, $arguments[0]); |
||
| 26 | |||
| 27 | return $this; |
||
| 28 | } |
||
| 29 | |||
| 30 | throw new BadMethodCallException("Method {$name} does not exist."); |
||
| 31 | } |
||
| 32 | } |
||
| 33 |