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

Concat in @commitlint/utils is not used #549

Closed
1 of 4 tasks
byCedric opened this issue Jan 27, 2019 · 3 comments
Closed
1 of 4 tasks

Concat in @commitlint/utils is not used #549

byCedric opened this issue Jan 27, 2019 · 3 comments

Comments

@byCedric
Copy link
Member

I ran a statistical code analyzer (SonarQube) to see if it can detect any issues, bugs or code smells that should be fixed. This one is kind of interesting.

Basically, the problem is that the problems.concat returns a brand new array. But this array is never stored or used anywhere. That means that either A) it isn't used and should be removed or B) should be used, but isn't right now.

I'm not sure if we should do something lime problems = problems.concat, so that's why I'm opening the issue.

Expected Behavior

Current Behavior

Affected packages

  • cli
  • core
  • prompt
  • config-angular

Possible Solution

Steps to Reproduce (for bugs)

Context

Your Environment

@marionebl
Copy link
Contributor

problems = problems.concat(...) is the right variant. Thanks for catching this.

@byCedric
Copy link
Member Author

Ok, I will create a PR to fix this! 😄

@byCedric
Copy link
Member Author

Merged into master, will be released in next release 😄

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

No branches or pull requests

2 participants