Code style should not follow Yoda style
This commit is contained in:
parent
b968513cb9
commit
4d46dde8d7
@ -6,7 +6,7 @@ $config = PhpCsFixer\Config::create()
|
||||
'@Symfony' => true,
|
||||
'align_multiline_comment' => false,
|
||||
'array_syntax' => ['syntax' => 'short'],
|
||||
'binary_operator_spaces' => ['align_double_arrow' => true, 'align_equals' => null],
|
||||
'binary_operator_spaces' => ['default' => null],
|
||||
'blank_line_before_statement' => ['statements' => ['return']],
|
||||
'combine_consecutive_unsets' => true,
|
||||
'concat_space' => ['spacing' => 'one'],
|
||||
@ -43,6 +43,7 @@ $config = PhpCsFixer\Config::create()
|
||||
'single_line_comment_style' => ['comment_types' => ['hash']],
|
||||
'strict_comparison' => true,
|
||||
'void_return' => true,
|
||||
'yoda_style' => ['equal' => false, 'identical' => false],
|
||||
]);
|
||||
|
||||
$config->setFinder(
|
||||
|
@ -18,7 +18,7 @@
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^5.7.0",
|
||||
"friendsofphp/php-cs-fixer": "^2.5.0"
|
||||
"friendsofphp/php-cs-fixer": "^2.7.0"
|
||||
},
|
||||
"suggest": {
|
||||
"ext-iconv": "To handle non UTF-8 CSV files (if \"php-intl\" is not already installed or is too limited)",
|
||||
|
@ -72,7 +72,7 @@ class Psr4Autoloader
|
||||
|
||||
// work backwards through the namespace names of the fully-qualified
|
||||
// class name to find a mapped file name
|
||||
while (false !== $pos = strrpos($prefix, '\\')) {
|
||||
while (($pos = strrpos($prefix, '\\')) !== false) {
|
||||
// retain the trailing namespace separator in the prefix
|
||||
$prefix = substr($class, 0, $pos + 1);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user