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 maxListeners option not supporting 0 #85

Merged
merged 1 commit into from
Jul 2, 2022
Merged

Fix maxListeners option not supporting 0 #85

merged 1 commit into from
Jul 2, 2022

Conversation

javierbrea
Copy link
Contributor

@javierbrea javierbrea commented Jul 1, 2022

Check if maxListeners option is a Number before setting default value instead of using a "truthy" comparison. This allows to give a 0 value to the option, which in Nodejs is a value that can be used to indicate an unlimited number of listeners.

closes #84


This change is Reviewable

@sonarqubecloud
Copy link

sonarqubecloud bot commented Jul 1, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@pustovitDmytro
Copy link
Owner

Thanks for fix!

@pustovitDmytro pustovitDmytro merged commit e0a4046 into pustovitDmytro:master Jul 2, 2022
pustovitDmytro pushed a commit that referenced this pull request Jul 2, 2022
## [1.1.10](v1.1.9...v1.1.10) (2022-07-02)

### Fix

* Check if maxListeners option is a Number before setting default value (#84) (#85) ([e0a4046](e0a4046)), closes [#84](#84) [#85](#85)
@pustovitDmytro
Copy link
Owner

🎉 This PR is included in version 1.1.10 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

maxListeners option does not support zero value
2 participants