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

fix(shelf-&-style): fix array compare and improve style #22

Conversation

syedsaadqamar
Copy link

#10

@ghost
Copy link

ghost commented Oct 12, 2019

DeepCode Report (#927760)

DeepCode analyzed this pull request.
There are no new issues.

Copy link
Owner

@jeffersonRibeiro jeffersonRibeiro left a comment

Choose a reason for hiding this comment

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

Hi Syed, thanks for submitting a pull request and solving the issue!

Could you remove the style? It Would be cool if this PR fix just the array checking


if (nextFilters !== this.props.filters) {
const { filters } = this.props;
if (nextFilters.length !== filters.length && JSON.stringify(nextFilters) !== JSON.stringify(filters)) {
Copy link
Owner

Choose a reason for hiding this comment

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

I think we don't need to deep check if the array of filters is not equal.

Just the length part is ok.

Choose a reason for hiding this comment

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

@jeffersonRibeiro, thanks for reviewing the PR I did changes that you suggested so you can check.

Copy link
Owner

@jeffersonRibeiro jeffersonRibeiro left a comment

Choose a reason for hiding this comment

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

Very cool! Thank you @Syed-Saad-Qamar !

@jeffersonRibeiro jeffersonRibeiro merged commit 0fb5570 into jeffersonRibeiro:master Oct 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants