Skip to content

Commit

Permalink
better wording for already included artist message
Browse files Browse the repository at this point in the history
  • Loading branch information
sam9116 committed Feb 12, 2024
1 parent 60e07d1 commit 8ec1b2e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/BaseInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,18 +90,17 @@ const BaseInput = forwardRef(({ setConcerts, setUserLocation, setMapStyle, start
var found = resJson.map(concert => concert.title).includes(concert.title);

if (found) {
alert(`${incomingArtistName} is already playing as part of ${concert.title} on ${formattedDate(concert.date)}`);
alert(`${incomingArtistName} is already performing as part of ${concert.title} on ${formattedDate(concert.date)}`);
return found;
}

});

if (!found) {
setAllConcerts((prev) => prev.concat(resJson));
sortArtist(allConcerts.concat(resJson), userLocation);
}

sortArtist(allConcerts.concat(resJson), userLocation);

} else {
console.log("Some error occured");
}
Expand Down

0 comments on commit 8ec1b2e

Please sign in to comment.