showDetails(cards, id){ cards.map(function(card, index){ if(card.id==id){ console.log(card); return card; } }) }