StyleCI fixes

This commit is contained in:
Dane Everitt 2017-03-12 19:38:50 -04:00
parent 668dc9216a
commit 2d90187c83
No known key found for this signature in database
GPG Key ID: EEA66103B3D71F53
3 changed files with 7 additions and 9 deletions

View File

@ -24,7 +24,6 @@
namespace Pterodactyl\Http\Controllers\Server;
use DB;
use Log;
use Uuid;
use Alert;

View File

@ -42,16 +42,15 @@ class ServiceVariable extends Model
*/
protected $guarded = ['id', 'created_at', 'updated_at'];
/**
* Cast values to correct type.
*
* @var array
*/
/**
* Cast values to correct type.
*
* @var array
*/
protected $casts = [
'option_id' => 'integer',
'user_viewable' => 'integer',
'user_editable' => 'integer',
'required' => 'integer',
];
/**
@ -62,7 +61,7 @@ class ServiceVariable extends Model
*/
public function getRequiredAttribute($value)
{
return ($this->rules === 'required' || str_contains($this->rules, ['required|', '|required']));
return $this->rules === 'required' || str_contains($this->rules, ['required|', '|required']);
}
/**

View File

@ -643,7 +643,7 @@ class ServerRepository
if ($validator->fails()) {
throw new DisplayValidationException(json_encode(
collect([
'notice' => ['There was a validation error with the `' . $variable->name . '` variable.']
'notice' => ['There was a validation error with the `' . $variable->name . '` variable.'],
])->merge($validator->errors()->toArray())
));
}