Prototype Practice.... lesson glitched


#1


this code initially passed an error but the save code button pushed to next lesson so i go back and review and press it again and this time no push through lesson but it errors now.... everything seems according to the lesson instructions.

function Cat(name, breed) {
    this.name = name;
    this.breed = breed;
    Cat.prototype.meow = function(){
    console.log("Meow");
}
};


// let's make some cats!
var cheshire = new Cat("Cheshire Cat", "British Shorthair");


cheshire.meow();

var gary = new Cat("Gary", "Domestic Shorthair");

gary.meow();


#2

this comes up now


#3

This should be outside of the constructor function.


#4

thank you
check out this next lesson. also passed but console error'd


#7

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.