Fixer removes indent on semicolon usage
iainhallam opened this issue · comments
I'm using php-cs-fixer v0.3.5.
When I type the semicolon at the end of a line in an otherwise well-formatted file (I have the ikappas.phpcs
extension as well), php-cs-fixer strips the indentation from the start of the line I've just typed. Disabling all extensions, then re-enabling just php-cs-fixer still shows the problem. I've removed my phpcs.xml from the root of the project, but that doesn't help.
Example:
public function getSort()
{
return 55
}
Type ;
:
public function getSort()
{
return 55;
}
I have the following in my settings for php-cs-fixer:
"php-cs-fixer.autoFixBySemicolon": true,
"php-cs-fixer.executablePath": "${extensionPath}/php-cs-fixer.phar",
"php-cs-fixer.lastDownload": 1661189450564,
Pressing Ctrl-Z undoes the faulty indentation, but this is a pain to have to do so I'm just disabling the feature for now.
Using "php-cs-fixer.onsave": true
doesn't cause the same loss of indentation.
Any thoughts on why this is happening?
fix, updated v0.3.6
Cool; that's fixed it, thanks.