| Conditions | 5 |
| Paths | 4 |
| Total Lines | 13 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 21 | protected function jsonColumn(Builder $query, Model $model, $column, $key) |
||
| 22 | { |
||
| 23 | $sql = $query->getQuery()->getGrammar()->wrap($column); |
||
| 24 | |||
| 25 | if ($model->getKeyName() === $key && in_array($model->getKeyType(), ['int', 'integer'])) { |
||
| 26 | $sql = '('.$sql.')::bigint'; |
||
| 27 | } |
||
| 28 | |||
| 29 | if ($model->hasCast($key) && $model->getCasts()[$key] === Uuid::class) { |
||
| 30 | $sql = '('.$sql.')::uuid'; |
||
| 31 | } |
||
| 32 | |||
| 33 | return new Expression($sql); |
||
| 34 | } |
||
| 48 |
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.