Skip to content

Commit

Permalink
style: Enable phpdoc_list_type fixer
Browse files Browse the repository at this point in the history
  • Loading branch information
paulbalandan committed Feb 14, 2024
1 parent 7d50bd3 commit e84e626
Show file tree
Hide file tree
Showing 12 changed files with 16 additions and 12 deletions.
1 change: 1 addition & 0 deletions .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@
'var',
],
],
'phpdoc_list_type' => true,
];

$options = [
Expand Down
4 changes: 3 additions & 1 deletion .php-cs-fixer.no-header.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,9 @@
__DIR__ . '/admin/starter/builds',
]);

$overrides = [];
$overrides = [
'phpdoc_list_type' => true,
];

$options = [
'cacheFile' => 'build/.php-cs-fixer.no-header.cache',
Expand Down
1 change: 1 addition & 0 deletions .php-cs-fixer.user-guide.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
'import_symbols' => false,
'leading_backslash_in_global_namespace' => true,
],
'phpdoc_list_type' => true,
];

$options = [
Expand Down
2 changes: 1 addition & 1 deletion app/Config/View.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class View extends BaseView
* by the core Parser by creating aliases that will be replaced with
* any callable. Can be single or tag pair.
*
* @var array<string, array<string>|callable|string>
* @var array<string, callable|list<string>|string>
* @phpstan-var array<string, array<ParserCallableString>|ParserCallableString|ParserCallable>
*/
public $plugins = [];
Expand Down
2 changes: 1 addition & 1 deletion system/Autoloader/Autoloader.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ class Autoloader
/**
* Stores namespaces as key, and path as values.
*
* @var array<string, array<string>>
* @var array<string, list<string>>
*/
protected $prefixes = [];

Expand Down
2 changes: 1 addition & 1 deletion system/Config/BaseService.php
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ class BaseService
/**
* A cache of the names of services classes found.
*
* @var array<string>
* @var list<string>
*/
private static array $serviceNames = [];

Expand Down
4 changes: 2 additions & 2 deletions system/Config/View.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class View extends BaseConfig
*
* @psalm-suppress UndefinedDocblockClass
*
* @var array<string, array<string>|callable|string>
* @var array<string, callable|list<string>|string>
* @phpstan-var array<string, array<parser_callable_string>|parser_callable_string|parser_callable>
*/
public $plugins = [];
Expand Down Expand Up @@ -89,7 +89,7 @@ class View extends BaseConfig
/**
* Built-in View plugins.
*
* @var array<string, array<string>|callable|string>
* @var array<string, callable|list<string>|string>
* @phpstan-var array<string, array<parser_callable_string>|parser_callable_string|parser_callable>
*/
protected $corePlugins = [
Expand Down
2 changes: 1 addition & 1 deletion system/Cookie/Exceptions/CookieException.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ public static function forInvalidSameSiteNone()
/**
* Thrown when the `CookieStore` class is filled with invalid Cookie objects.
*
* @param array<int|string> $data
* @param list<int|string> $data
*
* @return static
*/
Expand Down
2 changes: 1 addition & 1 deletion system/Database/BaseBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ class BaseBuilder
/**
* QB UNION data
*
* @var array<string>
* @var list<string>
*/
protected array $QBUnion = [];

Expand Down
4 changes: 2 additions & 2 deletions system/Events/Events.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class Events
* Stores information about the events
* for display in the debug toolbar.
*
* @var array<array<string, float|string>>
* @var list<array<string, float|string>>
*/
protected static $performanceLog = [];

Expand Down Expand Up @@ -275,7 +275,7 @@ public static function simulate(bool $choice = true)
/**
* Getter for the performance log records.
*
* @return array<array<string, float|string>>
* @return list<array<string, float|string>>
*/
public static function getPerformanceLogs()
{
Expand Down
2 changes: 1 addition & 1 deletion system/View/Parser.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class Parser extends View
/**
* Stores any plugins registered at run-time.
*
* @var array<string, array<string>|callable|string>
* @var array<string, callable|list<string>|string>
* @phpstan-var array<string, array<parser_callable_string>|parser_callable_string|parser_callable>
*/
protected $plugins = [];
Expand Down
2 changes: 1 addition & 1 deletion system/View/View.php
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ class View implements RendererInterface
* The name of the current section being rendered,
* if any.
*
* @var array<string>
* @var list<string>
*/
protected $sectionStack = [];

Expand Down

0 comments on commit e84e626

Please sign in to comment.