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

Uncaught Error when incorrect problem name selected #12

Open
anchat1990 opened this issue Jun 22, 2017 · 0 comments
Open

Uncaught Error when incorrect problem name selected #12

anchat1990 opened this issue Jun 22, 2017 · 0 comments

Comments

@anchat1990
Copy link

When trying out stream-adventure I found that a typo in the problem name when "select"ing problem leads to the following uncaught error

> 
> var p = adv.fn();
>                ^
> 
> TypeError: Cannot read property 'fn' of undefined
>     at Shop.select (/home/achatterjee/sandbox/stream-adventure/node_modules/adventure/index.js:248:16)
>     at Shop.execute (/home/achatterjee/sandbox/stream-adventure/node_modules/adventure/index.js:97:14)
>     at Object.<anonymous> (/home/achatterjee/sandbox/stream-adventure/bin/cmd.js:18:6)
>     at Module._compile (module.js:409:26)
>     at Object.Module._extensions..js (module.js:416:10)
>     at Module.load (module.js:343:32)
>     at Function.Module._load (module.js:300:12)
>     at Function.Module.runMain (module.js:441:10)
>     at startup (node.js:139:18)
>     at node.js:968:3
> 

I'm about to put in a pull request for this error to be caught and an informative error message to be displayed.

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