phpcs fixes

This commit is contained in:
Ron Bellido 2022-03-21 10:43:53 -07:00
parent 4b2fb46a4d
commit f1d1fb1a9f
4 changed files with 10 additions and 18 deletions

View File

@ -15,6 +15,7 @@ class FakeMetaCommand extends MetaCommand
// autoloader when it is done, and we certainly do not want to throw exceptions when we are simply checking if
// a certain class exists. We are instead changing this to be a noop.
return function () {};
return function () {
};
}
}

View File

@ -5,12 +5,7 @@ namespace Psalm\LaravelPlugin\Fakes;
use Barryvdh\LaravelIdeHelper\Console\ModelsCommand;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Filesystem\Filesystem;
use Illuminate\Support\Str;
use Psalm\LaravelPlugin\Handlers\Eloquent\Schema\SchemaAggregator;
use function config;
use function get_class;
use function implode;
use function in_array;
class FakeModelsCommand210 extends ModelsCommand
{
@ -30,7 +25,7 @@ class FakeModelsCommand210 extends ModelsCommand
*
* @param Model $model
*/
public function getPropertiesFromTable($model) : void
public function getPropertiesFromTable($model): void
{
$this->getProperties($model);
}

View File

@ -5,23 +5,18 @@ namespace Psalm\LaravelPlugin\Fakes;
use Barryvdh\LaravelIdeHelper\Console\ModelsCommand;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Filesystem\Filesystem;
use Illuminate\Support\Str;
use Psalm\LaravelPlugin\Handlers\Eloquent\Schema\SchemaAggregator;
use function config;
use function get_class;
use function implode;
use function in_array;
class FakeModelsCommand291 extends ModelsCommand
{
use FakeModelsCommandLogic;
/** @var SchemaAggregator */
private $schema;
/** @var array<class-string> */
private $model_classes = [];
use FakeModelsCommandLogic;
public function __construct(Filesystem $files, SchemaAggregator $schema)
{
parent::__construct($files);
@ -33,7 +28,7 @@ class FakeModelsCommand291 extends ModelsCommand
*
* @param Model $model
*/
protected function getPropertiesFromTable($model) : void
protected function getPropertiesFromTable($model): void
{
$this->getProperties($model);
}

View File

@ -8,9 +8,10 @@ use Illuminate\Filesystem\Filesystem;
use Psalm\LaravelPlugin\Fakes\FakeModelsCommand210;
use Psalm\LaravelPlugin\Fakes\FakeModelsCommand291;
use Psalm\LaravelPlugin\Handlers\Eloquent\Schema\SchemaAggregator;
use function \version_compare;
use function \assert;
use function \is_string;
use function version_compare;
use function assert;
use function is_string;
class FakeModelsCommandProvider
{