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

TypeError: Cannot read property 'properties' of undefined #12

Open
bertuccig opened this issue Sep 27, 2016 · 2 comments
Open

TypeError: Cannot read property 'properties' of undefined #12

bertuccig opened this issue Sep 27, 2016 · 2 comments

Comments

@bertuccig
Copy link

I receive an error "TypeError: Cannot read property 'properties' of undefined"
steps:

  • downloaded the swagger json file from my app
  • npm install phantomjs-pdf
  • I've ran "node index.js swagger.json" command

any suggestion?

@jjay225
Copy link
Collaborator

jjay225 commented Sep 27, 2016

Hi Bertuccig,

That error looks like it is coming from the "renderDefinition" function. Line 744 then it tries to access properties of the swagger definition on line 760. I would recommend adding a console.log in that function to see if there's an issue with the parameters being passed in.

@simonstewart
Copy link
Owner

Bertuccig,

I've run this against a sample file from Swagger.io and all seems to be OK. Can you double check the Swagger file is valid?
Are you running this on Windows?

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

3 participants