diff --git a/src/Components/TinderCards.js b/src/Components/TinderCards.js index 28542f1..edffa10 100644 --- a/src/Components/TinderCards.js +++ b/src/Components/TinderCards.js @@ -52,12 +52,10 @@ const useStyles = makeStyles({ position: "right", } }); - +const anime_set = new Set() const anime_map = [] async function getAllAnimeTitleFromDb() { try { - //const usersCollectionRef = collection(firestore, 'users'); - // Create a query to get documents where the age field is greater than the threshold //const q = query(usersCollectionRef, where('animeTitle')); @@ -67,6 +65,8 @@ async function getAllAnimeTitleFromDb() { querySnapshot.forEach(doc => { console.log(doc.data().animeTitle) anime_map.push(doc.data().animeTitle.toString()) + + anime_set.add(doc.data().animeTitle.toString()) }); } catch (error) { @@ -82,28 +82,15 @@ getTopAnime() .then(responseData => { for (var i=0; i