I need a help in Advanced objects: exercise 5 (Getters)

What the ■■■■ is wrong with this exercise???
in task 2, my solution was:

const robot = {
  _model: '1E78V2',
  _energyLevel: 100,
  get energyLevel () {
    if (typeof this._energyLevel === "number" ) {
      return 'My current enery level is ' + this._energyLevel }
  }
};

But it says wrong why??? and i have also tried with ${} but it still says wrong! please help.

hello @joewilliam0901679842 you might need to wholly complete the sentence … after the + this._energyLevel add an +’ ’ ( an empty string ) so that it looks like …+ this._energyLevel +’ ’

hope it helps

Nope, I forgot to write g in word energy in return sentence :joy:.

1 Like

oh ok …sometimes my tests have failed because of lack of semicolons…but glad it worked out for you

1 Like