-
Notifications
You must be signed in to change notification settings - Fork 67
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
Accept to generate when called without the options parameter. #14
Accept to generate when called without the options parameter. #14
Conversation
When options is not provided, defaults are used. This allow to call generate() and generateMultiple() without having to provide an empty options object when defaults are wanted.
Current coverage is 100% (diff: 100%)@@ master #14 diff @@
===================================
Files 1 1
Lines 43 44 +1
Methods 0 0
Messages 0 0
Branches 0 0
===================================
+ Hits 43 44 +1
Misses 0 0
Partials 0 0
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for taking the time to put this together! I left a small comment about the docs but it's looking really great, especially keeping the test coverage.
@@ -30,7 +31,9 @@ console.log(password); | |||
|
|||
#### `generateMultiple(amount, options)` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think you could change this to how it's done in the node docs, like this?
#### generateMultiple(amount[, options])`
Then we can do away with the "If the options parameter is not provided, yadda yadda.." which I think is somewhat redundant. Please do that with the above one too please :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure thing !
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for submitting this PR! It looks great 👍
When options is not provided, defaults are used. This allow to call
generate() and generateMultiple() without having to provide an empty
options object when defaults are wanted.
README and tests updated accordingly. package.json's version left as-is.