Recursive function.
function objSearch(serObj){
// For loop through the object.
for( prop in serObj ){
// If the property is price get the price.
if(prop === 'price'){
// Got the price property now return the value of price.
console.log('I have price...', prop, '=', serObj[prop]);
// If the property is an object send it through the function again.
} else if(typeof serObj[prop] === 'object'){
// Pass the nested object.
objSearch(serObj[prop]);
}
}
}
objSearch(obj);