About last row i cant understand it properly

Tell us what’s happening:
Describe your issue in detail here.

  **Your code so far**

function checkObj(obj, checkProp) {
// Only change code below this line4
var obj={
  gift:"pony",
  pet:"kitten",
  bed:"sleigh",
  city:"Seattle"
}
if(obj.hasOwnProperty(checkProp))
{
  return obj[checkProp];
}
else if(obj.hasOwnProperty(checkProp)!== true)
{
  return "Not Found";
}else{
return "Change Me!";
}
checkObj("pet");
// Only change code above this line
}
  **Your browser information:**

User Agent is: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.110 Safari/537.36

Challenge: Testing Objects for Properties

Link to the challenge:

?
You didn’t ask any questions or tell us what’s going on.

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