Skip to content

Check for dependencies and peerDependencies before calling Object.keys #11

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

Merged
merged 1 commit into from
Sep 27, 2015

Conversation

daviferreira
Copy link
Contributor

Got this error when trying to run the examples on your input-autosize component:

var dependencies = Object.keys(pkg.dependencies);
                              ^
TypeError: Object.keys called on non-object

This PR simply check for the existence of deps and peerDeps. Maybe we should also check for its type? Or just try/catch? 💃

Cheers!

@JedWatson
Copy link
Owner

👍 thanks @daviferreira

JedWatson added a commit that referenced this pull request Sep 27, 2015
Check for dependencies and peerDependencies before calling Object.keys
@JedWatson JedWatson merged commit 5556c88 into JedWatson:master Sep 27, 2015
@JedWatson
Copy link
Owner

Published as v0.7.3

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

Successfully merging this pull request may close these issues.

2 participants