Skip to content

Commit

Permalink
Update app.js
Browse files Browse the repository at this point in the history
  • Loading branch information
jsalzer312 committed May 28, 2024
1 parent 0ce6c3d commit dfb3bdf
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -584,10 +584,12 @@ function loadContacts(jsonObject){
if(jsonObject.contacts[i].Favorited===1){
document.getElementById("contact-not-fave-"+parseInt(i+1)).style = "none";
document.getElementById("contact-fave-"+parseInt(i+1)).style = "flex";
console.log(jsonObject.contacts[i].FirstName+"contact is favorite");
}
else{
document.getElementById("contact-fave-"+parseInt(i+1)).style = "none";
document.getElementById("contact-not-fave-"+parseInt(i+1)).style = "flex";
console.log(jsonObject.contacts[i].FirstName+"contact is not a favorite");
}
document.getElementById("contact-first-name-"+parseInt(i+1)).textContent = jsonObject.contacts[i].FirstName;
document.getElementById("contact-last-name-"+parseInt(i+1)).textContent = jsonObject.contacts[i].LastName;
Expand Down

0 comments on commit dfb3bdf

Please sign in to comment.