Fork me on GitHub
a Sensio Labs Product

I ate three cookies πŸͺ (v3.40.2) edition

Rule no_trailing_comma_in_list_callΒΆ

Remove trailing commas in list function calls.

WarningΒΆ

This rule is deprecated and will be removed in the next major versionΒΆ

You should use no_trailing_comma_in_singleline instead.

ExamplesΒΆ

Example #1ΒΆ

--- Original
+++ New
 <?php
-list($a, $b,) = foo();
+list($a, $b) = foo();

Source classΒΆ

PhpCsFixer\Fixer\ControlStructure\NoTrailingCommaInListCallFixer