Skip to content

Commit

Permalink
Apply fixes from StyleCI
Browse files Browse the repository at this point in the history
  • Loading branch information
TLingC authored and StyleCIBot committed Feb 28, 2020
1 parent dc2b08c commit aad7c34
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 22 deletions.
6 changes: 3 additions & 3 deletions src/Resources/Allocation.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ class Allocation extends Resource
/**
* The id of the allocation.
*
* @var integer
* @var int
*/
public $id;

Expand All @@ -28,14 +28,14 @@ class Allocation extends Resource
/**
* The port of the allocation.
*
* @var integer
* @var int
*/
public $port;

/**
* The assign status of the allocation.
*
* @var boolean
* @var bool
*/
public $assigned;
}
3 changes: 2 additions & 1 deletion src/Resources/Location.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,9 @@ public function update(array $data = [])
{
$data = array_merge([
'short' => $this->short,
'long' => $this->long
'long' => $this->long,
], $data);

return $this->pterodactyl->updateLocation($this->id, $data);
}
}
25 changes: 14 additions & 11 deletions src/Resources/Server.php
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ class Server extends Resource
* @var array
*/
public $limits = [];

/**
* The feature limits of the server.
*
Expand All @@ -108,7 +108,7 @@ class Server extends Resource
* @var array
*/
public $allocations = [];

/**
* The container of the server.
*
Expand Down Expand Up @@ -165,8 +165,9 @@ public function updateDetails(array $data = [])
{
$data = array_merge([
'name' => $this->name,
'user' => $this->user
'user' => $this->user,
], $data);

return $this->pterodactyl->updateServerDetails($this->id, $data);
}

Expand All @@ -178,10 +179,11 @@ public function updateDetails(array $data = [])
public function updateBuild(array $data = [])
{
$data = array_merge([
'allocation' => $this->allocation,
'limits' => $this->limits,
'feature_limits' => $this->featureLimits
'allocation' => $this->allocation,
'limits' => $this->limits,
'feature_limits' => $this->featureLimits,
], $data);

return $this->pterodactyl->updateServerBuild($this->id, $data);
}

Expand All @@ -193,12 +195,13 @@ public function updateBuild(array $data = [])
public function updateStartup(array $data = [])
{
$data = array_merge([
'startup' => $this->container['startup_command'],
'egg' => $this->egg,
'image' => $this->container['image'],
'environment' => $this->container['environment'],
'skip_scripts' => 0
'startup' => $this->container['startup_command'],
'egg' => $this->egg,
'image' => $this->container['image'],
'environment' => $this->container['environment'],
'skip_scripts' => 0,
], $data);

return $this->pterodactyl->updateServerStartup($this->id, $data);
}

Expand Down
15 changes: 8 additions & 7 deletions src/Resources/User.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,21 @@ class User extends Resource
/**
* The id of the user.
*
* @var integer
* @var int
*/
public $id;

/**
* The external id of the user.
*
* @var integer
* @var int
*/
public $externalId;

/**
* The uuid of the user.
*
* @var integer
* @var int
*/
public $uuid;

Expand Down Expand Up @@ -63,7 +63,7 @@ class User extends Resource
/**
* If a user is an admin.
*
* @var integer
* @var int
*/
public $rootAdmin;

Expand Down Expand Up @@ -106,11 +106,12 @@ public function delete()
public function update(array $data = [])
{
$data = array_merge([
'username' => $this->username,
'email' => $this->email,
'username' => $this->username,
'email' => $this->email,
'first_name' => $this->firstName,
'last_name' => $this->lastName
'last_name' => $this->lastName,
], $data);

return $this->pterodactyl->updateUser($this->id, $data);
}
}

0 comments on commit aad7c34

Please sign in to comment.