nacholibre / node-readlines

Read large text files line by line (synchronous) for Node.js
MIT License
162 stars 28 forks source link

Allow using 0 as file descriptor #34

Open janmarthedal opened 3 years ago

janmarthedal commented 3 years ago

The standard unix file descriptor for stdin is 0 (also available as process.stdin.fd), but this is not possible to use since 0 is a falsy value. This commit fixes this.

nacholibre commented 3 years ago

@janmarthedal Thanks for the contribution, I'll test it and add it in the next release if everything works as expected.