Fix casting

This commit is contained in:
Dane Everitt 2020-09-13 10:04:30 -07:00
parent 9a4c0d8ba7
commit 6ec2ae9df8
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53

View file

@ -43,13 +43,8 @@ class Mount extends Model
*
* @var array
*/
protected $attributes = [
protected $casts = [
'id' => 'int',
'uuid' => 'string',
'name' => 'string',
'description' => 'string',
'source' => 'string',
'target' => 'string',
'read_only' => 'bool',
'user_mountable' => 'bool',
];
@ -60,7 +55,6 @@ class Mount extends Model
* @var string
*/
public static $validationRules = [
// 'uuid' => 'required|string|size:36|unique:mounts,uuid',
'name' => 'required|string|min:2|max:64|unique:mounts,name',
'description' => 'nullable|string|max:255',
'source' => 'required|string',