| Total Complexity | 3 |
| Total Lines | 34 |
| Duplicated Lines | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 13 | trait UpdatesEntity |
||
| 14 | { |
||
| 15 | /** |
||
| 16 | * Finds a model with ID and updates it with given properties. |
||
| 17 | * |
||
| 18 | * @param int|string $modelId |
||
| 19 | * @param mixed $properties |
||
| 20 | * |
||
| 21 | * @return Builder|Model |
||
| 22 | */ |
||
| 23 | public function findAndUpdate($modelId, $properties) |
||
| 28 | } |
||
| 29 | |||
| 30 | /** |
||
| 31 | * Updates a model given properties. |
||
| 32 | * |
||
| 33 | * @param Model $model |
||
| 34 | * @param mixed $properties |
||
| 35 | * |
||
| 36 | * @return Builder|Model |
||
| 37 | */ |
||
| 38 | public function update($model, $properties) |
||
| 49 |