Run cs-fix, ensure we only install dependency versions supporting 7.4+

This commit is contained in:
DaneEveritt 2022-05-04 19:01:29 -04:00
parent 3e55a79439
commit 34ffaebd3e
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
16 changed files with 154 additions and 290 deletions

11
.gitignore vendored
View file

@ -15,26 +15,17 @@ node_modules
_ide_helper.php _ide_helper.php
_ide_helper_models.php _ide_helper_models.php
.phpstorm.meta.php .phpstorm.meta.php
.php_cs.cache
.yarn .yarn
public/assets/manifest.json public/assets/manifest.json
# For local development with docker # For local development with docker
# Remove if we ever put the Dockerfile in the repo # Remove if we ever put the Dockerfile in the repo
.dockerignore .dockerignore
#Dockerfile
docker-compose.yml docker-compose.yml
# for image related files # for image related files
misc misc
.phpstorm.meta.php .php-cs-fixer.cache
.php_cs.cache
coverage.xml coverage.xml
# Vagrant
*.log
resources/lang/locales.js resources/lang/locales.js
resources/assets/pterodactyl/scripts/helpers/ziggy.js
resources/assets/scripts/helpers/ziggy.js
.phpunit.result.cache .phpunit.result.cache

View file

@ -29,7 +29,7 @@ return (new Config())
'no_unreachable_default_argument_value' => true, 'no_unreachable_default_argument_value' => true,
'no_useless_return' => true, 'no_useless_return' => true,
'ordered_imports' => [ 'ordered_imports' => [
'sortAlgorithm' => 'length', 'sort_algorithm' => 'length',
], ],
'phpdoc_align' => [ 'phpdoc_align' => [
'align' => 'left', 'align' => 'left',

View file

@ -114,6 +114,7 @@ class AppSettingsCommand extends Command
foreach ($validator->errors()->all() as $error) { foreach ($validator->errors()->all() as $error) {
$this->output->error($error); $this->output->error($error);
} }
return 1; return 1;
} }

View file

@ -46,7 +46,6 @@ class MakeNodeCommand extends Command
*/ */
protected $description = 'Creates a new node on the system via the CLI.'; protected $description = 'Creates a new node on the system via the CLI.';
/** /**
* Handle the command execution process. * Handle the command execution process.
* *
@ -62,13 +61,18 @@ class MakeNodeCommand extends Command
$data['fqdn'] = $this->option('fqdn') ?? $this->ask('Enter a domain name (e.g node.example.com) to be used for connecting to the daemon. An IP address may only be used if you are not using SSL for this node'); $data['fqdn'] = $this->option('fqdn') ?? $this->ask('Enter a domain name (e.g node.example.com) to be used for connecting to the daemon. An IP address may only be used if you are not using SSL for this node');
if (!filter_var(gethostbyname($data['fqdn']), FILTER_VALIDATE_IP)) { if (!filter_var(gethostbyname($data['fqdn']), FILTER_VALIDATE_IP)) {
$this->error('The FQDN or IP address provided does not resolve to a valid IP address.'); $this->error('The FQDN or IP address provided does not resolve to a valid IP address.');
return; return;
} }
$data['public'] = $this->option('public') ?? $this->confirm('Should this node be public? As a note, setting a node to private you will be denying the ability to auto-deploy to this node.', true); $data['public'] = $this->option('public') ?? $this->confirm('Should this node be public? As a note, setting a node to private you will be denying the ability to auto-deploy to this node.', true);
$data['scheme'] = $this->option('scheme') ?? $this->anticipate('Please either enter https for SSL or http for a non-ssl connection', $data['scheme'] = $this->option('scheme') ?? $this->anticipate(
["https","http",],"https"); 'Please either enter https for SSL or http for a non-ssl connection',
['https', 'http'],
'https'
);
if (filter_var($data['fqdn'], FILTER_VALIDATE_IP) && $data['scheme'] === 'https') { if (filter_var($data['fqdn'], FILTER_VALIDATE_IP) && $data['scheme'] === 'https') {
$this->error('A fully qualified domain name that resolves to a public IP address is required in order to use SSL for this node.'); $this->error('A fully qualified domain name that resolves to a public IP address is required in order to use SSL for this node.');
return; return;
} }
$data['behind_proxy'] = $this->option('proxy') ?? $this->confirm('Is your FQDN behind a proxy?'); $data['behind_proxy'] = $this->option('proxy') ?? $this->confirm('Is your FQDN behind a proxy?');

View file

@ -69,7 +69,7 @@ class ProcessRunnableCommand extends Command
'schedule' => $schedule->name, 'schedule' => $schedule->name,
'hash' => $schedule->hashid, 'hash' => $schedule->hashid,
])); ]));
} catch (Throwable | Exception $exception) { } catch (Throwable|Exception $exception) {
Log::error($exception, ['schedule_id' => $schedule->id]); Log::error($exception, ['schedule_id' => $schedule->id]);
$this->error("An error was encountered while processing Schedule #{$schedule->id}: " . $exception->getMessage()); $this->error("An error was encountered while processing Schedule #{$schedule->id}: " . $exception->getMessage());

View file

@ -87,6 +87,7 @@ class UpgradeCommand extends Command
if (!$this->confirm('Are you sure you want to run the upgrade process for your Panel?')) { if (!$this->confirm('Are you sure you want to run the upgrade process for your Panel?')) {
$this->warn('Upgrade process terminated by user.'); $this->warn('Upgrade process terminated by user.');
return; return;
} }
} }

View file

@ -128,8 +128,6 @@ class ServerTransferController extends Controller
/** /**
* The daemon notifies us about a transfer success. * The daemon notifies us about a transfer success.
* *
* @return \Illuminate\Http\JsonResponse
*
* @throws \Throwable * @throws \Throwable
*/ */
public function success(string $uuid): JsonResponse public function success(string $uuid): JsonResponse

View file

@ -92,9 +92,6 @@ abstract class AbstractLoginController extends Controller
/** /**
* Determine if the user is logging in using an email or username,. * Determine if the user is logging in using an email or username,.
*
* @param string|null $input
* @return string
*/ */
protected function getField(string $input = null): string protected function getField(string $input = null): string
{ {

View file

@ -2,8 +2,8 @@
namespace Pterodactyl\Http\Controllers\Auth; namespace Pterodactyl\Http\Controllers\Auth;
use Carbon\CarbonInterface;
use Carbon\CarbonImmutable; use Carbon\CarbonImmutable;
use Carbon\CarbonInterface;
use Pterodactyl\Models\User; use Pterodactyl\Models\User;
use Illuminate\Http\JsonResponse; use Illuminate\Http\JsonResponse;
use PragmaRX\Google2FA\Google2FA; use PragmaRX\Google2FA\Google2FA;
@ -110,9 +110,6 @@ class LoginCheckpointController extends AbstractLoginController
* Determines if the data provided from the session is valid or not. This * Determines if the data provided from the session is valid or not. This
* will return false if the data is invalid, or if more time has passed than * will return false if the data is invalid, or if more time has passed than
* was configured when the session was written. * was configured when the session was written.
*
* @param array $data
* @return bool
*/ */
protected function hasValidSessionData(array $data): bool protected function hasValidSessionData(array $data): bool
{ {

View file

@ -28,7 +28,7 @@ class VerifyCsrfToken extends BaseVerifier
* to using Sanctum for the API endpoints, which handles that for us automatically. * to using Sanctum for the API endpoints, which handles that for us automatically.
* *
* @param \Illuminate\Http\Request $request * @param \Illuminate\Http\Request $request
* @param \Closure $next *
* @return mixed * @return mixed
* *
* @throws \Illuminate\Session\TokenMismatchException * @throws \Illuminate\Session\TokenMismatchException

View file

@ -33,8 +33,6 @@ class BuildModificationService
* BuildModificationService constructor. * BuildModificationService constructor.
* *
* @param \Pterodactyl\Services\Servers\ServerConfigurationStructureService $structureService * @param \Pterodactyl\Services\Servers\ServerConfigurationStructureService $structureService
* @param \Illuminate\Database\ConnectionInterface $connection
* @param \Pterodactyl\Repositories\Wings\DaemonServerRepository $daemonServerRepository
*/ */
public function __construct( public function __construct(
ServerConfigurationStructureService $structureService, ServerConfigurationStructureService $structureService,
@ -57,7 +55,7 @@ class BuildModificationService
public function handle(Server $server, array $data) public function handle(Server $server, array $data)
{ {
/** @var \Pterodactyl\Models\Server $server */ /** @var \Pterodactyl\Models\Server $server */
$server = $this->connection->transaction(function() use ($server, $data) { $server = $this->connection->transaction(function () use ($server, $data) {
$this->processAllocations($server, $data); $this->processAllocations($server, $data);
if (isset($data['allocation_id']) && $data['allocation_id'] != $server->allocation_id) { if (isset($data['allocation_id']) && $data['allocation_id'] != $server->allocation_id) {

View file

@ -47,7 +47,7 @@
"barryvdh/laravel-ide-helper": "^2.12", "barryvdh/laravel-ide-helper": "^2.12",
"facade/ignition": "^2.17", "facade/ignition": "^2.17",
"fakerphp/faker": "^1.19", "fakerphp/faker": "^1.19",
"friendsofphp/php-cs-fixer": "^2.19", "friendsofphp/php-cs-fixer": "^3.8",
"laravel/dusk": "^6.23", "laravel/dusk": "^6.23",
"mockery/mockery": "^1.5", "mockery/mockery": "^1.5",
"nunomaduro/collision": "^5.11", "nunomaduro/collision": "^5.11",
@ -70,7 +70,8 @@
} }
}, },
"scripts": { "scripts": {
"php-cs-fixer": "php-cs-fixer fix --diff --diff-format=udiff --config=./.php_cs.dist", "cs:fix": "php-cs-fixer fix",
"cs:check": "php-cs-fixer fix --dry-run --diff --verbose",
"post-root-package-install": [ "post-root-package-install": [
"@php -r \"file_exists('.env') || copy('.env.example', '.env');\"" "@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
], ],
@ -84,6 +85,9 @@
}, },
"prefer-stable": true, "prefer-stable": true,
"config": { "config": {
"platform": {
"php": "7.4.0"
},
"preferred-install": "dist", "preferred-install": "dist",
"sort-packages": true, "sort-packages": true,
"optimize-autoloader": false "optimize-autoloader": false

383
composer.lock generated
View file

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "accb145afef8466a6ff78639f2b7b097", "content-hash": "257d04481ad578251164aa3124c2ee2f",
"packages": [ "packages": [
{ {
"name": "aws/aws-crt-php", "name": "aws/aws-crt-php",
@ -1916,31 +1916,31 @@
}, },
{ {
"name": "lcobucci/clock", "name": "lcobucci/clock",
"version": "2.2.0", "version": "2.0.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/lcobucci/clock.git", "url": "https://github.com/lcobucci/clock.git",
"reference": "fb533e093fd61321bfcbac08b131ce805fe183d3" "reference": "353d83fe2e6ae95745b16b3d911813df6a05bfb3"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/lcobucci/clock/zipball/fb533e093fd61321bfcbac08b131ce805fe183d3", "url": "https://api.github.com/repos/lcobucci/clock/zipball/353d83fe2e6ae95745b16b3d911813df6a05bfb3",
"reference": "fb533e093fd61321bfcbac08b131ce805fe183d3", "reference": "353d83fe2e6ae95745b16b3d911813df6a05bfb3",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"php": "^8.0", "php": "^7.4 || ^8.0"
"stella-maris/clock": "^0.1.4"
}, },
"require-dev": { "require-dev": {
"infection/infection": "^0.26", "infection/infection": "^0.17",
"lcobucci/coding-standard": "^8.0", "lcobucci/coding-standard": "^6.0",
"phpstan/extension-installer": "^1.1", "phpstan/extension-installer": "^1.0",
"phpstan/phpstan": "^0.12", "phpstan/phpstan": "^0.12",
"phpstan/phpstan-deprecation-rules": "^0.12", "phpstan/phpstan-deprecation-rules": "^0.12",
"phpstan/phpstan-phpunit": "^0.12", "phpstan/phpstan-phpunit": "^0.12",
"phpstan/phpstan-strict-rules": "^0.12", "phpstan/phpstan-strict-rules": "^0.12",
"phpunit/phpunit": "^9.5" "phpunit/php-code-coverage": "9.1.4",
"phpunit/phpunit": "9.3.7"
}, },
"type": "library", "type": "library",
"autoload": { "autoload": {
@ -1961,7 +1961,7 @@
"description": "Yet another clock abstraction", "description": "Yet another clock abstraction",
"support": { "support": {
"issues": "https://github.com/lcobucci/clock/issues", "issues": "https://github.com/lcobucci/clock/issues",
"source": "https://github.com/lcobucci/clock/tree/2.2.0" "source": "https://github.com/lcobucci/clock/tree/2.0.x"
}, },
"funding": [ "funding": [
{ {
@ -1973,7 +1973,7 @@
"type": "patreon" "type": "patreon"
} }
], ],
"time": "2022-04-19T19:34:17+00:00" "time": "2020-08-27T18:56:02+00:00"
}, },
{ {
"name": "lcobucci/jwt", "name": "lcobucci/jwt",
@ -3829,30 +3829,30 @@
}, },
{ {
"name": "psr/log", "name": "psr/log",
"version": "2.0.0", "version": "1.1.4",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/php-fig/log.git", "url": "https://github.com/php-fig/log.git",
"reference": "ef29f6d262798707a9edd554e2b82517ef3a9376" "reference": "d49695b909c3b7628b6289db5479a1c204601f11"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/php-fig/log/zipball/ef29f6d262798707a9edd554e2b82517ef3a9376", "url": "https://api.github.com/repos/php-fig/log/zipball/d49695b909c3b7628b6289db5479a1c204601f11",
"reference": "ef29f6d262798707a9edd554e2b82517ef3a9376", "reference": "d49695b909c3b7628b6289db5479a1c204601f11",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"php": ">=8.0.0" "php": ">=5.3.0"
}, },
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-master": "2.0.x-dev" "dev-master": "1.1.x-dev"
} }
}, },
"autoload": { "autoload": {
"psr-4": { "psr-4": {
"Psr\\Log\\": "src" "Psr\\Log\\": "Psr/Log/"
} }
}, },
"notification-url": "https://packagist.org/downloads/", "notification-url": "https://packagist.org/downloads/",
@ -3873,9 +3873,9 @@
"psr-3" "psr-3"
], ],
"support": { "support": {
"source": "https://github.com/php-fig/log/tree/2.0.0" "source": "https://github.com/php-fig/log/tree/1.1.4"
}, },
"time": "2021-07-14T16:41:46+00:00" "time": "2021-05-03T11:20:27+00:00"
}, },
{ {
"name": "psr/simple-cache", "name": "psr/simple-cache",
@ -4131,24 +4131,25 @@
}, },
{ {
"name": "ramsey/uuid", "name": "ramsey/uuid",
"version": "4.3.1", "version": "4.2.3",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/ramsey/uuid.git", "url": "https://github.com/ramsey/uuid.git",
"reference": "8505afd4fea63b81a85d3b7b53ac3cb8dc347c28" "reference": "fc9bb7fb5388691fd7373cd44dcb4d63bbcf24df"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/ramsey/uuid/zipball/8505afd4fea63b81a85d3b7b53ac3cb8dc347c28", "url": "https://api.github.com/repos/ramsey/uuid/zipball/fc9bb7fb5388691fd7373cd44dcb4d63bbcf24df",
"reference": "8505afd4fea63b81a85d3b7b53ac3cb8dc347c28", "reference": "fc9bb7fb5388691fd7373cd44dcb4d63bbcf24df",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"brick/math": "^0.8 || ^0.9", "brick/math": "^0.8 || ^0.9",
"ext-ctype": "*",
"ext-json": "*", "ext-json": "*",
"php": "^8.0", "php": "^7.2 || ^8.0",
"ramsey/collection": "^1.0" "ramsey/collection": "^1.0",
"symfony/polyfill-ctype": "^1.8",
"symfony/polyfill-php80": "^1.14"
}, },
"replace": { "replace": {
"rhumsaa/uuid": "self.version" "rhumsaa/uuid": "self.version"
@ -4185,6 +4186,9 @@
}, },
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": {
"dev-main": "4.x-dev"
},
"captainhook": { "captainhook": {
"force-install": true "force-install": true
} }
@ -4209,7 +4213,7 @@
], ],
"support": { "support": {
"issues": "https://github.com/ramsey/uuid/issues", "issues": "https://github.com/ramsey/uuid/issues",
"source": "https://github.com/ramsey/uuid/tree/4.3.1" "source": "https://github.com/ramsey/uuid/tree/4.2.3"
}, },
"funding": [ "funding": [
{ {
@ -4221,7 +4225,7 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2022-03-27T21:42:02+00:00" "time": "2021-09-25T23:10:38+00:00"
}, },
{ {
"name": "s1lentium/iptools", "name": "s1lentium/iptools",
@ -4542,53 +4546,6 @@
], ],
"time": "2021-08-19T18:23:06+00:00" "time": "2021-08-19T18:23:06+00:00"
}, },
{
"name": "stella-maris/clock",
"version": "0.1.4",
"source": {
"type": "git",
"url": "https://gitlab.com/stella-maris/clock.git",
"reference": "8a0a967896df4c63417385dc69328a0aec84d9cf"
},
"dist": {
"type": "zip",
"url": "https://gitlab.com/api/v4/projects/stella-maris%2Fclock/repository/archive.zip?sha=8a0a967896df4c63417385dc69328a0aec84d9cf",
"reference": "8a0a967896df4c63417385dc69328a0aec84d9cf",
"shasum": ""
},
"require": {
"php": "^7.0|^8.0"
},
"type": "library",
"autoload": {
"psr-4": {
"StellaMaris\\Clock\\": "src"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Andreas Heigl",
"role": "Maintainer"
}
],
"description": "A pre-release of the proposed PSR-20 Clock-Interface",
"homepage": "https://gitlab.com/stella-maris/clock",
"keywords": [
"clock",
"datetime",
"point in time",
"psr20"
],
"support": {
"issues": "https://gitlab.com/stella-maris/clock/-/issues",
"source": "https://gitlab.com/stella-maris/clock/-/tree/0.1.4"
},
"time": "2022-04-17T14:12:26+00:00"
},
{ {
"name": "swiftmailer/swiftmailer", "name": "swiftmailer/swiftmailer",
"version": "v6.3.0", "version": "v6.3.0",
@ -4766,20 +4723,21 @@
}, },
{ {
"name": "symfony/css-selector", "name": "symfony/css-selector",
"version": "v6.0.3", "version": "v5.4.3",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/css-selector.git", "url": "https://github.com/symfony/css-selector.git",
"reference": "1955d595c12c111629cc814d3f2a2ff13580508a" "reference": "b0a190285cd95cb019237851205b8140ef6e368e"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/css-selector/zipball/1955d595c12c111629cc814d3f2a2ff13580508a", "url": "https://api.github.com/repos/symfony/css-selector/zipball/b0a190285cd95cb019237851205b8140ef6e368e",
"reference": "1955d595c12c111629cc814d3f2a2ff13580508a", "reference": "b0a190285cd95cb019237851205b8140ef6e368e",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"php": ">=8.0.2" "php": ">=7.2.5",
"symfony/polyfill-php80": "^1.16"
}, },
"type": "library", "type": "library",
"autoload": { "autoload": {
@ -4811,7 +4769,7 @@
"description": "Converts CSS selectors to XPath expressions", "description": "Converts CSS selectors to XPath expressions",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"support": { "support": {
"source": "https://github.com/symfony/css-selector/tree/v6.0.3" "source": "https://github.com/symfony/css-selector/tree/v5.4.3"
}, },
"funding": [ "funding": [
{ {
@ -4827,29 +4785,29 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2022-01-02T09:55:41+00:00" "time": "2022-01-02T09:53:40+00:00"
}, },
{ {
"name": "symfony/deprecation-contracts", "name": "symfony/deprecation-contracts",
"version": "v3.0.1", "version": "v2.5.1",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/deprecation-contracts.git", "url": "https://github.com/symfony/deprecation-contracts.git",
"reference": "26954b3d62a6c5fd0ea8a2a00c0353a14978d05c" "reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/26954b3d62a6c5fd0ea8a2a00c0353a14978d05c", "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/e8b495ea28c1d97b5e0c121748d6f9b53d075c66",
"reference": "26954b3d62a6c5fd0ea8a2a00c0353a14978d05c", "reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"php": ">=8.0.2" "php": ">=7.1"
}, },
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "3.0-dev" "dev-main": "2.5-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/contracts", "name": "symfony/contracts",
@ -4878,7 +4836,7 @@
"description": "A generic function and convention to trigger deprecation notices", "description": "A generic function and convention to trigger deprecation notices",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"support": { "support": {
"source": "https://github.com/symfony/deprecation-contracts/tree/v3.0.1" "source": "https://github.com/symfony/deprecation-contracts/tree/v2.5.1"
}, },
"funding": [ "funding": [
{ {
@ -4894,7 +4852,7 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2022-01-02T09:55:41+00:00" "time": "2022-01-02T09:53:40+00:00"
}, },
{ {
"name": "symfony/error-handler", "name": "symfony/error-handler",
@ -5054,20 +5012,20 @@
}, },
{ {
"name": "symfony/event-dispatcher-contracts", "name": "symfony/event-dispatcher-contracts",
"version": "v3.0.1", "version": "v2.5.1",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/event-dispatcher-contracts.git", "url": "https://github.com/symfony/event-dispatcher-contracts.git",
"reference": "7bc61cc2db649b4637d331240c5346dcc7708051" "reference": "f98b54df6ad059855739db6fcbc2d36995283fe1"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/7bc61cc2db649b4637d331240c5346dcc7708051", "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/f98b54df6ad059855739db6fcbc2d36995283fe1",
"reference": "7bc61cc2db649b4637d331240c5346dcc7708051", "reference": "f98b54df6ad059855739db6fcbc2d36995283fe1",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"php": ">=8.0.2", "php": ">=7.2.5",
"psr/event-dispatcher": "^1" "psr/event-dispatcher": "^1"
}, },
"suggest": { "suggest": {
@ -5076,7 +5034,7 @@
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "3.0-dev" "dev-main": "2.5-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/contracts", "name": "symfony/contracts",
@ -5113,7 +5071,7 @@
"standards" "standards"
], ],
"support": { "support": {
"source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.0.1" "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v2.5.1"
}, },
"funding": [ "funding": [
{ {
@ -5129,7 +5087,7 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2022-01-02T09:55:41+00:00" "time": "2022-01-02T09:53:40+00:00"
}, },
{ {
"name": "symfony/finder", "name": "symfony/finder",
@ -6584,33 +6542,34 @@
}, },
{ {
"name": "symfony/string", "name": "symfony/string",
"version": "v6.0.8", "version": "v5.4.8",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/string.git", "url": "https://github.com/symfony/string.git",
"reference": "ac0aa5c2282e0de624c175b68d13f2c8f2e2649d" "reference": "3c061a76bff6d6ea427d85e12ad1bb8ed8cd43e8"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/string/zipball/ac0aa5c2282e0de624c175b68d13f2c8f2e2649d", "url": "https://api.github.com/repos/symfony/string/zipball/3c061a76bff6d6ea427d85e12ad1bb8ed8cd43e8",
"reference": "ac0aa5c2282e0de624c175b68d13f2c8f2e2649d", "reference": "3c061a76bff6d6ea427d85e12ad1bb8ed8cd43e8",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"php": ">=8.0.2", "php": ">=7.2.5",
"symfony/polyfill-ctype": "~1.8", "symfony/polyfill-ctype": "~1.8",
"symfony/polyfill-intl-grapheme": "~1.0", "symfony/polyfill-intl-grapheme": "~1.0",
"symfony/polyfill-intl-normalizer": "~1.0", "symfony/polyfill-intl-normalizer": "~1.0",
"symfony/polyfill-mbstring": "~1.0" "symfony/polyfill-mbstring": "~1.0",
"symfony/polyfill-php80": "~1.15"
}, },
"conflict": { "conflict": {
"symfony/translation-contracts": "<2.0" "symfony/translation-contracts": ">=3.0"
}, },
"require-dev": { "require-dev": {
"symfony/error-handler": "^5.4|^6.0", "symfony/error-handler": "^4.4|^5.0|^6.0",
"symfony/http-client": "^5.4|^6.0", "symfony/http-client": "^4.4|^5.0|^6.0",
"symfony/translation-contracts": "^2.0|^3.0", "symfony/translation-contracts": "^1.1|^2",
"symfony/var-exporter": "^5.4|^6.0" "symfony/var-exporter": "^4.4|^5.0|^6.0"
}, },
"type": "library", "type": "library",
"autoload": { "autoload": {
@ -6649,7 +6608,7 @@
"utf8" "utf8"
], ],
"support": { "support": {
"source": "https://github.com/symfony/string/tree/v6.0.8" "source": "https://github.com/symfony/string/tree/v5.4.8"
}, },
"funding": [ "funding": [
{ {
@ -6665,7 +6624,7 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2022-04-22T08:18:02+00:00" "time": "2022-04-19T10:40:37+00:00"
}, },
{ {
"name": "symfony/translation", "name": "symfony/translation",
@ -7654,25 +7613,27 @@
}, },
{ {
"name": "composer/xdebug-handler", "name": "composer/xdebug-handler",
"version": "2.0.2", "version": "3.0.3",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/composer/xdebug-handler.git", "url": "https://github.com/composer/xdebug-handler.git",
"reference": "84674dd3a7575ba617f5a76d7e9e29a7d3891339" "reference": "ced299686f41dce890debac69273b47ffe98a40c"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/composer/xdebug-handler/zipball/84674dd3a7575ba617f5a76d7e9e29a7d3891339", "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/ced299686f41dce890debac69273b47ffe98a40c",
"reference": "84674dd3a7575ba617f5a76d7e9e29a7d3891339", "reference": "ced299686f41dce890debac69273b47ffe98a40c",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"php": "^5.3.2 || ^7.0 || ^8.0", "composer/pcre": "^1 || ^2 || ^3",
"php": "^7.2.5 || ^8.0",
"psr/log": "^1 || ^2 || ^3" "psr/log": "^1 || ^2 || ^3"
}, },
"require-dev": { "require-dev": {
"phpstan/phpstan": "^0.12.55", "phpstan/phpstan": "^1.0",
"symfony/phpunit-bridge": "^4.2 || ^5" "phpstan/phpstan-strict-rules": "^1.1",
"symfony/phpunit-bridge": "^6.0"
}, },
"type": "library", "type": "library",
"autoload": { "autoload": {
@ -7698,7 +7659,7 @@
"support": { "support": {
"irc": "irc://irc.freenode.org/composer", "irc": "irc://irc.freenode.org/composer",
"issues": "https://github.com/composer/xdebug-handler/issues", "issues": "https://github.com/composer/xdebug-handler/issues",
"source": "https://github.com/composer/xdebug-handler/tree/2.0.2" "source": "https://github.com/composer/xdebug-handler/tree/3.0.3"
}, },
"funding": [ "funding": [
{ {
@ -7714,7 +7675,7 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2021-07-31T17:03:58+00:00" "time": "2022-02-25T21:32:43+00:00"
}, },
{ {
"name": "doctrine/annotations", "name": "doctrine/annotations",
@ -8194,85 +8155,65 @@
}, },
{ {
"name": "friendsofphp/php-cs-fixer", "name": "friendsofphp/php-cs-fixer",
"version": "v2.19.3", "version": "v3.8.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/FriendsOfPHP/PHP-CS-Fixer.git", "url": "https://github.com/FriendsOfPHP/PHP-CS-Fixer.git",
"reference": "75ac86f33fab4714ea5a39a396784d83ae3b5ed8" "reference": "cbad1115aac4b5c3c5540e7210d3c9fba2f81fa3"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/75ac86f33fab4714ea5a39a396784d83ae3b5ed8", "url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/cbad1115aac4b5c3c5540e7210d3c9fba2f81fa3",
"reference": "75ac86f33fab4714ea5a39a396784d83ae3b5ed8", "reference": "cbad1115aac4b5c3c5540e7210d3c9fba2f81fa3",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"composer/semver": "^1.4 || ^2.0 || ^3.0", "composer/semver": "^3.2",
"composer/xdebug-handler": "^1.2 || ^2.0", "composer/xdebug-handler": "^3.0.3",
"doctrine/annotations": "^1.2", "doctrine/annotations": "^1.13",
"ext-json": "*", "ext-json": "*",
"ext-tokenizer": "*", "ext-tokenizer": "*",
"php": "^5.6 || ^7.0 || ^8.0", "php": "^7.4 || ^8.0",
"php-cs-fixer/diff": "^1.3", "php-cs-fixer/diff": "^2.0",
"symfony/console": "^3.4.43 || ^4.1.6 || ^5.0", "symfony/console": "^5.4 || ^6.0",
"symfony/event-dispatcher": "^3.0 || ^4.0 || ^5.0", "symfony/event-dispatcher": "^5.4 || ^6.0",
"symfony/filesystem": "^3.0 || ^4.0 || ^5.0", "symfony/filesystem": "^5.4 || ^6.0",
"symfony/finder": "^3.0 || ^4.0 || ^5.0", "symfony/finder": "^5.4 || ^6.0",
"symfony/options-resolver": "^3.0 || ^4.0 || ^5.0", "symfony/options-resolver": "^5.4 || ^6.0",
"symfony/polyfill-php70": "^1.0", "symfony/polyfill-mbstring": "^1.23",
"symfony/polyfill-php72": "^1.4", "symfony/polyfill-php80": "^1.25",
"symfony/process": "^3.0 || ^4.0 || ^5.0", "symfony/polyfill-php81": "^1.25",
"symfony/stopwatch": "^3.0 || ^4.0 || ^5.0" "symfony/process": "^5.4 || ^6.0",
"symfony/stopwatch": "^5.4 || ^6.0"
}, },
"require-dev": { "require-dev": {
"justinrainbow/json-schema": "^5.0", "justinrainbow/json-schema": "^5.2",
"keradus/cli-executor": "^1.4", "keradus/cli-executor": "^1.5",
"mikey179/vfsstream": "^1.6", "mikey179/vfsstream": "^1.6.10",
"php-coveralls/php-coveralls": "^2.4.2", "php-coveralls/php-coveralls": "^2.5.2",
"php-cs-fixer/accessible-object": "^1.0", "php-cs-fixer/accessible-object": "^1.1",
"php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.2", "php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.2",
"php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.2.1", "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.2.1",
"phpspec/prophecy-phpunit": "^1.1 || ^2.0", "phpspec/prophecy": "^1.15",
"phpunit/phpunit": "^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.13 || ^9.5", "phpspec/prophecy-phpunit": "^2.0",
"phpunit/phpunit": "^9.5",
"phpunitgoodpractices/polyfill": "^1.5", "phpunitgoodpractices/polyfill": "^1.5",
"phpunitgoodpractices/traits": "^1.9.1", "phpunitgoodpractices/traits": "^1.9.1",
"sanmai/phpunit-legacy-adapter": "^6.4 || ^8.2.1", "symfony/phpunit-bridge": "^6.0",
"symfony/phpunit-bridge": "^5.2.1", "symfony/yaml": "^5.4 || ^6.0"
"symfony/yaml": "^3.0 || ^4.0 || ^5.0"
}, },
"suggest": { "suggest": {
"ext-dom": "For handling output formats in XML", "ext-dom": "For handling output formats in XML",
"ext-mbstring": "For handling non-UTF8 characters.", "ext-mbstring": "For handling non-UTF8 characters."
"php-cs-fixer/phpunit-constraint-isidenticalstring": "For IsIdenticalString constraint.",
"php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "For XmlMatchesXsd constraint.",
"symfony/polyfill-mbstring": "When enabling `ext-mbstring` is not possible."
}, },
"bin": [ "bin": [
"php-cs-fixer" "php-cs-fixer"
], ],
"type": "application", "type": "application",
"extra": {
"branch-alias": {
"dev-master": "2.19-dev"
}
},
"autoload": { "autoload": {
"psr-4": { "psr-4": {
"PhpCsFixer\\": "src/" "PhpCsFixer\\": "src/"
}, }
"classmap": [
"tests/Test/AbstractFixerTestCase.php",
"tests/Test/AbstractIntegrationCaseFactory.php",
"tests/Test/AbstractIntegrationTestCase.php",
"tests/Test/Assert/AssertTokensTrait.php",
"tests/Test/IntegrationCase.php",
"tests/Test/IntegrationCaseFactory.php",
"tests/Test/IntegrationCaseFactoryInterface.php",
"tests/Test/InternalIntegrationCaseFactory.php",
"tests/Test/IsIdenticalConstraint.php",
"tests/Test/TokensWithObservedTransformers.php",
"tests/TestCase.php"
]
}, },
"notification-url": "https://packagist.org/downloads/", "notification-url": "https://packagist.org/downloads/",
"license": [ "license": [
@ -8291,7 +8232,7 @@
"description": "A tool to automatically fix PHP code style", "description": "A tool to automatically fix PHP code style",
"support": { "support": {
"issues": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/issues", "issues": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/issues",
"source": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/tree/v2.19.3" "source": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/tree/v3.8.0"
}, },
"funding": [ "funding": [
{ {
@ -8299,7 +8240,7 @@
"type": "github" "type": "github"
} }
], ],
"time": "2021-11-15T17:17:55+00:00" "time": "2022-03-18T17:20:59+00:00"
}, },
{ {
"name": "hamcrest/hamcrest-php", "name": "hamcrest/hamcrest-php",
@ -8822,16 +8763,16 @@
}, },
{ {
"name": "php-cs-fixer/diff", "name": "php-cs-fixer/diff",
"version": "v1.3.1", "version": "v2.0.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/PHP-CS-Fixer/diff.git", "url": "https://github.com/PHP-CS-Fixer/diff.git",
"reference": "dbd31aeb251639ac0b9e7e29405c1441907f5759" "reference": "29dc0d507e838c4580d018bd8b5cb412474f7ec3"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/PHP-CS-Fixer/diff/zipball/dbd31aeb251639ac0b9e7e29405c1441907f5759", "url": "https://api.github.com/repos/PHP-CS-Fixer/diff/zipball/29dc0d507e838c4580d018bd8b5cb412474f7ec3",
"reference": "dbd31aeb251639ac0b9e7e29405c1441907f5759", "reference": "29dc0d507e838c4580d018bd8b5cb412474f7ec3",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
@ -8859,21 +8800,18 @@
{ {
"name": "Kore Nordmann", "name": "Kore Nordmann",
"email": "mail@kore-nordmann.de" "email": "mail@kore-nordmann.de"
},
{
"name": "SpacePossum"
} }
], ],
"description": "sebastian/diff v2 backport support for PHP5.6", "description": "sebastian/diff v3 backport support for PHP 5.6+",
"homepage": "https://github.com/PHP-CS-Fixer", "homepage": "https://github.com/PHP-CS-Fixer",
"keywords": [ "keywords": [
"diff" "diff"
], ],
"support": { "support": {
"issues": "https://github.com/PHP-CS-Fixer/diff/issues", "issues": "https://github.com/PHP-CS-Fixer/diff/issues",
"source": "https://github.com/PHP-CS-Fixer/diff/tree/v1.3.1" "source": "https://github.com/PHP-CS-Fixer/diff/tree/v2.0.2"
}, },
"time": "2020-10-14T08:39:05+00:00" "time": "2020-10-14T08:32:19+00:00"
}, },
{ {
"name": "php-mock/php-mock", "name": "php-mock/php-mock",
@ -10943,74 +10881,6 @@
], ],
"time": "2022-01-02T09:53:40+00:00" "time": "2022-01-02T09:53:40+00:00"
}, },
{
"name": "symfony/polyfill-php70",
"version": "v1.20.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-php70.git",
"reference": "5f03a781d984aae42cebd18e7912fa80f02ee644"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-php70/zipball/5f03a781d984aae42cebd18e7912fa80f02ee644",
"reference": "5f03a781d984aae42cebd18e7912fa80f02ee644",
"shasum": ""
},
"require": {
"php": ">=7.1"
},
"type": "metapackage",
"extra": {
"branch-alias": {
"dev-main": "1.20-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Nicolas Grekas",
"email": "p@tchwork.com"
},
{
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"description": "Symfony polyfill backporting some PHP 7.0+ features to lower PHP versions",
"homepage": "https://symfony.com",
"keywords": [
"compatibility",
"polyfill",
"portable",
"shim"
],
"support": {
"source": "https://github.com/symfony/polyfill-php70/tree/v1.20.0"
},
"funding": [
{
"url": "https://symfony.com/sponsor",
"type": "custom"
},
{
"url": "https://github.com/fabpot",
"type": "github"
},
{
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
"type": "tidelift"
}
],
"time": "2020-10-23T14:02:19+00:00"
},
{ {
"name": "symfony/stopwatch", "name": "symfony/stopwatch",
"version": "v5.4.5", "version": "v5.4.5",
@ -11138,5 +11008,8 @@
"ext-zip": "*" "ext-zip": "*"
}, },
"platform-dev": [], "platform-dev": [],
"plugin-api-version": "2.3.0" "platform-overrides": {
"php": "7.4.0"
},
"plugin-api-version": "2.2.0"
} }

View file

@ -130,7 +130,7 @@ return [
'full_log' => false, 'full_log' => false,
], ],
'views' => [ 'views' => [
'data' => false, //Note: Can slow down the application, because the data can be quite large.. 'data' => false, // Note: Can slow down the application, because the data can be quite large..
], ],
'route' => [ 'route' => [
'label' => true, // show complete route on bar 'label' => true, // show complete route on bar

View file

@ -5,9 +5,9 @@ namespace Pterodactyl\Tests\Integration\Api\Application\Location;
use Pterodactyl\Models\Node; use Pterodactyl\Models\Node;
use Illuminate\Http\Response; use Illuminate\Http\Response;
use Pterodactyl\Models\Location; use Pterodactyl\Models\Location;
use Pterodactyl\Transformers\Api\Application\LocationTransformer;
use Pterodactyl\Transformers\Api\Application\NodeTransformer; use Pterodactyl\Transformers\Api\Application\NodeTransformer;
use Pterodactyl\Transformers\Api\Application\ServerTransformer; use Pterodactyl\Transformers\Api\Application\ServerTransformer;
use Pterodactyl\Transformers\Api\Application\LocationTransformer;
use Pterodactyl\Tests\Integration\Api\Application\ApplicationApiIntegrationTestCase; use Pterodactyl\Tests\Integration\Api\Application\ApplicationApiIntegrationTestCase;
class LocationControllerTest extends ApplicationApiIntegrationTestCase class LocationControllerTest extends ApplicationApiIntegrationTestCase
@ -128,13 +128,13 @@ class LocationControllerTest extends ApplicationApiIntegrationTestCase
$response = $this->patchJson('/api/application/locations/' . $location->id, [ $response = $this->patchJson('/api/application/locations/' . $location->id, [
'short' => 'new inhouse', 'short' => 'new inhouse',
'long' => 'This is my new inhouse location' 'long' => 'This is my new inhouse location',
]); ]);
$response->assertStatus(Response::HTTP_OK); $response->assertStatus(Response::HTTP_OK);
$response->assertJsonCount(2); $response->assertJsonCount(2);
$response->assertJsonStructure([ $response->assertJsonStructure([
'object', 'object',
'attributes' => ['id', 'short', 'long', 'created_at', 'updated_at'] 'attributes' => ['id', 'short', 'long', 'created_at', 'updated_at'],
]); ]);
$this->assertDatabaseHas('locations', ['short' => 'new inhouse', 'long' => 'This is my new inhouse location']); $this->assertDatabaseHas('locations', ['short' => 'new inhouse', 'long' => 'This is my new inhouse location']);

View file

@ -52,7 +52,7 @@ class DeployServerDatabaseServiceTest extends IntegrationTestCase
$server = $this->createServerModel(); $server = $this->createServerModel();
$this->expectException(InvalidArgumentException::class); $this->expectException(InvalidArgumentException::class);
$this->expectExceptionMessageMatches('/^Expected a non-empty value\. Got: /', ); $this->expectExceptionMessageMatches('/^Expected a non-empty value\. Got: /');
$this->getService()->handle($server, $data); $this->getService()->handle($server, $data);
} }