Profile Lookup: not pass

Hello,
Profile Lookup
When I test each case manually, my code works. But it doesn’t pass the test. :upside_down_face:

function lookUpProfile(name, prop) {
  // Only change code below this line
for (var profil in contacts) {
  if (contacts[profil].firstName === name) {
    if (contacts[profil].hasOwnProperty(prop)) {
      console.log(contacts[profil][prop])
      return profil[prop]
    } else {
      console.log('No such property')
      return 'No such property';
      }
    } 
  }
    console.log('No such contact')
    return 'No such contact';
  
  // Only change code above this line
}

I see a mismatch here between what you return and what you log, make sure you debug your algorithm properly

Thank you a lot Ilenia :wink: