Skip to content
This repository has been archived by the owner on Dec 23, 2018. It is now read-only.

added a if for the case when defaults don't exist #40

Merged
merged 1 commit into from
Mar 21, 2014

Conversation

daviddias
Copy link
Contributor

I was trying to run the example given on the README and got always a error because of the optional arguments:

/Users/david/Code/nsp/node_modules/celeri/lib/plugins/help.js:135
            if(ops.defaults[op]) {
                           ^
TypeError: Cannot read property '--age' of undefined

So I confined the for loop in a if statement to make sure that doesn't get executed if .defaults doesn't exist, so far is working right. I'm not sure thought if 'defaults' was actually a typo and should it by optional (because that makes it work too)

crcn pushed a commit that referenced this pull request Mar 21, 2014
added a if for the case when defaults don't exist
@crcn crcn merged commit 57a35f2 into crcn:master Mar 21, 2014
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants