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

Static Pages don't load, unhandled promise error thrown #1644

Closed
ErisDS opened this issue Dec 9, 2013 · 0 comments · Fixed by #1650
Closed

Static Pages don't load, unhandled promise error thrown #1644

ErisDS opened this issue Dec 9, 2013 · 0 comments · Fixed by #1650
Labels
bug [triage] something behaving unexpectedly
Milestone

Comments

@ErisDS
Copy link
Member

ErisDS commented Dec 9, 2013

Issue Summary

When trying to visit the URL for a published static page (with or without a trailing slash) the page spins and eventually timesout.

Steps to Reproduce

  1. Create a new static page and publish it
  2. Try to visit the page via the URL

Server console outputs the following error message:

[promises] Unhandled rejections: 1
[ { reason: [TypeError: Cannot call method 'hasOwnProperty' of undefined],
    message: 'TypeError: Cannot call method \'hasOwnProperty\' of undefined',
    stack: 
     [ '=== Unhandled rejection escaped at ===',
       '    at Object.read (/Users/hannah/Ghost/Ghost/core/server/api/settings.js:129:53)',
       '    at /Users/hannah/Ghost/Ghost/core/server/controllers/frontend.js:74:34',
       '  --- new call stack ---',
       '    at Object.read (/Users/hannah/Ghost/Ghost/core/server/api/settings.js:129:20)',
       '    at /Users/hannah/Ghost/Ghost/core/server/controllers/frontend.js:74:34',
       '  --- new call stack ---',
       '    at Object.read (/Users/hannah/Ghost/Ghost/core/server/api/settings.js:129:20)',
       '    at /Users/hannah/Ghost/Ghost/core/server/controllers/frontend.js:74:34',
       '=== Caused by reason ===',
       'TypeError: Cannot call method \'hasOwnProperty\' of undefined',
       '    at /Users/hannah/Ghost/Ghost/core/server/controllers/frontend.js:76:48' ] } ]

Technical details:

  • Ghost Version: master (latest commit: 365b4ca)
  • Node Version: 0.10.18
hswolff added a commit to hswolff/Ghost that referenced this issue Dec 10, 2013
fixes TryGhost#1644

- Fixes bug in controller/frontend
- Created functional test for posts API to test for this bug
- Created unit tests for frontend controller
- Fixed a global variable leak in core/test/utils/fixtures/data-generator
that was leaking the DataGenerator globally
- Resolved issue that arose from fixing above bug
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug [triage] something behaving unexpectedly
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant