Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PropertyLabelSpacing JS fixer issue when there is no space after colon #466

Closed
sertand opened this issue Jan 30, 2015 · 3 comments
Closed

Comments

@sertand
Copy link
Member

sertand commented Jan 30, 2015

When fixing the following code PHPCS adds extra spaces between the string and the closing brace. Fixer works fine when there is a single space after phpcs:

// Original code:
fn.phpcs(
    {phpcs:'rocks my world'}
);

// After running fixer:
fn.phpcs(
    {phpcs:'rocks my world'    }
);
@aik099
Copy link
Contributor

aik099 commented Jan 30, 2015

Please specify PHP_CodeSniffer version and used standard.

@gsherwood
Copy link
Member

Looks to be latest PHPCS with Squiz standard running over JS.

The fixable error is There must be a single space after the colon in a property/label declaration but the fix is incorrect when there are no spaces after the colon.

@gsherwood gsherwood changed the title PHPCS Fixer issue when there is no space after colon PropertyLabelSpacing JS fixer issue when there is no space after colon Feb 2, 2015
gsherwood added a commit that referenced this issue Feb 2, 2015
@gsherwood
Copy link
Member

This is now fixed. Thanks for reporting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants