@@ -135,7 +135,7 @@ discard block |
||
| 135 | 135 | // the model in a variable, which we will then use in the closure. |
| 136 | 136 | $model = $this; |
| 137 | 137 | |
| 138 | - return static::unguarded(function () use ($model, $attributes) { |
|
| 138 | + return static::unguarded(function() use ($model, $attributes) { |
|
| 139 | 139 | return $model->fill($attributes); |
| 140 | 140 | }); |
| 141 | 141 | } |
@@ -165,7 +165,7 @@ discard block |
||
| 165 | 165 | */ |
| 166 | 166 | public function newInstance(array $attributes = []) |
| 167 | 167 | { |
| 168 | - return new static((array) $attributes); |
|
| 168 | + return new static((array)$attributes); |
|
| 169 | 169 | } |
| 170 | 170 | |
| 171 | 171 | /** |
@@ -179,7 +179,7 @@ discard block |
||
| 179 | 179 | { |
| 180 | 180 | $instance = new static(); |
| 181 | 181 | |
| 182 | - $items = array_map(function ($item) use ($instance) { |
|
| 182 | + $items = array_map(function($item) use ($instance) { |
|
| 183 | 183 | return $instance->newInstance($item); |
| 184 | 184 | }, $items); |
| 185 | 185 | |
@@ -233,7 +233,7 @@ discard block |
||
| 233 | 233 | */ |
| 234 | 234 | public function withHidden($attributes) |
| 235 | 235 | { |
| 236 | - $this->hidden = array_diff($this->hidden, (array) $attributes); |
|
| 236 | + $this->hidden = array_diff($this->hidden, (array)$attributes); |
|
| 237 | 237 | |
| 238 | 238 | return $this; |
| 239 | 239 | } |
@@ -712,16 +712,16 @@ discard block |
||
| 712 | 712 | switch ($this->getCastType($key)) { |
| 713 | 713 | case 'int': |
| 714 | 714 | case 'integer': |
| 715 | - return (int) $value; |
|
| 715 | + return (int)$value; |
|
| 716 | 716 | case 'real': |
| 717 | 717 | case 'float': |
| 718 | 718 | case 'double': |
| 719 | - return (float) $value; |
|
| 719 | + return (float)$value; |
|
| 720 | 720 | case 'string': |
| 721 | - return (string) $value; |
|
| 721 | + return (string)$value; |
|
| 722 | 722 | case 'bool': |
| 723 | 723 | case 'boolean': |
| 724 | - return (bool) $value; |
|
| 724 | + return (bool)$value; |
|
| 725 | 725 | case 'object': |
| 726 | 726 | return $this->fromJson($value, true); |
| 727 | 727 | case 'array': |