Use more standardized phpcs
This commit is contained in:
parent
a043071e3c
commit
c449ca5155
493 changed files with 1116 additions and 3903 deletions
|
@ -45,12 +45,6 @@ class HostUpdateService
|
|||
|
||||
/**
|
||||
* DatabaseHostService constructor.
|
||||
*
|
||||
* @param \Illuminate\Database\ConnectionInterface $connection
|
||||
* @param \Illuminate\Database\DatabaseManager $databaseManager
|
||||
* @param \Pterodactyl\Contracts\Repository\DatabaseHostRepositoryInterface $repository
|
||||
* @param \Pterodactyl\Extensions\DynamicDatabaseConnection $dynamic
|
||||
* @param \Illuminate\Contracts\Encryption\Encrypter $encrypter
|
||||
*/
|
||||
public function __construct(
|
||||
ConnectionInterface $connection,
|
||||
|
@ -69,15 +63,11 @@ class HostUpdateService
|
|||
/**
|
||||
* Update a database host and persist to the database.
|
||||
*
|
||||
* @param int $hostId
|
||||
* @param array $data
|
||||
* @return \Pterodactyl\Models\DatabaseHost
|
||||
*
|
||||
* @throws \Throwable
|
||||
*/
|
||||
public function handle(int $hostId, array $data): DatabaseHost
|
||||
{
|
||||
if (! empty(array_get($data, 'password'))) {
|
||||
if (!empty(array_get($data, 'password'))) {
|
||||
$data['password'] = $this->encrypter->encrypt($data['password']);
|
||||
} else {
|
||||
unset($data['password']);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue