Skip to content

Commit 45c2f9c

Browse files
committed
constructors.js complete.
1 parent 5d08d7f commit 45c2f9c

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎constructors.js‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ function Animal(options) {
99
}
1010

1111
Animal.prototype.grow = function() {
12-
console.log('${this.name} grew larger!');
12+
return '${this.name} grew larger!');
1313
};
1414

1515
// problem #2
@@ -19,7 +19,7 @@ Animal.prototype.grow = function() {
1919
// instances of Cat should also have access to the 'grow' method
2020

2121
function Cat(options) {
22-
Animal.call(this, catOptions);
22+
Animal.call(this, options);
2323
this.isCat = catOptions.isCat;
2424
}
2525

0 commit comments

Comments
 (0)