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

change error message for list components commands #101

Open
nitzantomer opened this issue Aug 30, 2017 · 0 comments
Open

change error message for list components commands #101

nitzantomer opened this issue Aug 30, 2017 · 0 comments
Labels

Comments

@nitzantomer
Copy link
Member

nitzantomer commented Aug 30, 2017

right now the functions look like this:

return fugazi.components.registry.getModule(props.path).getCommands().map(componentToStruct);

but if fugazi.components.registry.getModule(props.path) returns undefined then the error message is:

Cannot read property 'getCommands' of undefined

instead first the commands need to check whether the module exists, if not return that as an error message and only if it does continue

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

No branches or pull requests

1 participant