I hat happens to my code i can't pass my challenge?

Tell us what’s happening:

Your code so far

// Setup
var myObj = {
 gift: "pony",
 pet: "kitten",
 bed: "sleigh"

function checkObj(checkProp) {
 // Your Code Here
 return myObj[checkProp]
 return "not found"

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/82.0.4068.4 Safari/537.36.

Challenge: Testing Objects for Properties

Link to the challenge:

You’ve got a couple sticking points in your code here!

Remember that when passing an argument into a function you should treat it like a variable. So:
should be

also remember to pass the tests, you’ll want to match the exact casing the directions tell you to provide for each result. (hint: “not found” probably is missing one or more capital letters).

1 Like

Thank you it works,now