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

Find edge case in no-access-state-in-setstate (#1597) #1598

Merged
merged 2 commits into from Dec 13, 2017

Conversation

jaaberg
Copy link
Contributor

@jaaberg jaaberg commented Dec 11, 2017

This fixes #1597.

This also fixes another bug I found where the following were reported as an error (added a new test case for this):

var nextValueNotUsed = this.state.value + 1;
var nextValue = 2;
this.setState({value: nextValue});

Copy link
Member

@ljharb ljharb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems reasonable

@ljharb ljharb added the bug label Dec 13, 2017
@ljharb ljharb merged commit a908eb3 into jsx-eslint:master Dec 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

no-access-state-in-setstate bug?
3 participants