Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript Object-Oriented JavaScript (2015) Practice Project User Interface Code

Daniel Sarmiento
Daniel Sarmiento
10,265 Points

Buttons don't work

I'm getting this errors in the console

Uncaught TypeError: Cannot read property 'isCorrectAnswer' of undefined at Quiz.guess (quiz.js:8) at HTMLButtonElement.button.onclick (quiz_ui.js:35)

Here's the workspace snapshot: https://w.trhou.se/x7sa2ludpi

2 Answers

Jennifer Nordell
seal-mask
STAFF
.a{fill-rule:evenodd;}techdegree
Jennifer Nordell
Treehouse Teacher

Hi there! You've simply made a small typo. In the quiz_ui.js file you've written this:

QuizUI.displayNext;

But you forgot the parentheses. It should be:

QuizUI.displayNext();

Try making that change and then refreshing the page.

Hope this helps! :sparkles:

Same thing happened to me. It drove me crazy for like an hour! hahaha. Guess I should have looked here first.