@@ -25,7 +25,7 @@ discard block |
||
| 25 | 25 | $nums = $this->filterNum($value); |
| 26 | 26 | $slugs = $this->filterSlugs($value); |
| 27 | 27 | |
| 28 | - return $builder->where(function (Builder $builder) use ($nums, $slugs) { |
|
| 28 | + return $builder->where(function(Builder $builder) use ($nums, $slugs) { |
|
| 29 | 29 | $builder |
| 30 | 30 | ->whereIn('id', $nums) |
| 31 | 31 | ->orWhereIn('slug', $slugs); |
@@ -51,21 +51,21 @@ discard block |
||
| 51 | 51 | */ |
| 52 | 52 | protected function map($values): array |
| 53 | 53 | { |
| 54 | - return array_map(function ($value) { |
|
| 54 | + return array_map(function($value) { |
|
| 55 | 55 | return $this->getId($value); |
| 56 | 56 | }, $this->toArray($values)); |
| 57 | 57 | } |
| 58 | 58 | |
| 59 | 59 | protected function filterNum(array $values): array |
| 60 | 60 | { |
| 61 | - return array_filter($values, function ($value) { |
|
| 61 | + return array_filter($values, function($value) { |
|
| 62 | 62 | return is_numeric($value); |
| 63 | 63 | }); |
| 64 | 64 | } |
| 65 | 65 | |
| 66 | 66 | protected function filterSlugs(array $values): array |
| 67 | 67 | { |
| 68 | - return array_filter($values, function ($value) { |
|
| 68 | + return array_filter($values, function($value) { |
|
| 69 | 69 | return ! is_numeric($value); |
| 70 | 70 | }); |
| 71 | 71 | } |
@@ -76,7 +76,7 @@ discard block |
||
| 76 | 76 | return [$values]; |
| 77 | 77 | } elseif ($this->isArrayable($values)) { |
| 78 | 78 | $values = $values->toArray(); |
| 79 | - } elseif (! $this->isArray($values)) { |
|
| 79 | + } elseif ( ! $this->isArray($values)) { |
|
| 80 | 80 | $values = Arr::wrap($values); |
| 81 | 81 | } |
| 82 | 82 | |