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

Declare lineArray further down in the code #4

Open
c3ho opened this issue Sep 25, 2020 · 1 comment
Open

Declare lineArray further down in the code #4

c3ho opened this issue Sep 25, 2020 · 1 comment

Comments

@c3ho
Copy link

c3ho commented Sep 25, 2020

lineArray = data.toString().split("\n");

I noticed this line is only used here, you can declare it here instead of up top since you're not appending to it or anything.
Otherwise you're initializing it as an empty array only to overwrite it with the value from your .filter().

const lineArray = data.toString().split("\n");

@c3ho
Copy link
Author

c3ho commented Sep 25, 2020

Sorry see issue #5 first before fixing this one

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

No branches or pull requests

1 participant