Tell us what’s happening:
Describe your issue in detail here.
**Your code so far**
function checkObj(obj, checkProp) {
var result =""
// Only change code below this line
obj={
"gift": "pony",
"pet": "kitten",
"bed" : "sleigh",
"city" : "Seattle",
};
if (obj.hasOwnProperty(checkProp)){
result = obj[checkProp];
return result
}
else{
return "Not Found";
}
// Only change code above this line
}
i am getting this eror
// running tests
checkObj({pet: "kitten", bed: "sleigh"}, "gift") should return the string Not Found.
// tests completed
unable to understand. Please help
**Your browser information:**
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/102.0.0.0 Safari/537.36
sorry I did not notice it earlier, you are not supposed to create obj of your own, when function checkObj is called the obj is created and given as argument