Skip to content

Commit

Permalink
Ajuste Front
Browse files Browse the repository at this point in the history
  • Loading branch information
GugaDavi committed Aug 9, 2019
1 parent ca9dae3 commit 795475f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions front-tindev/src/pages/Main/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,16 @@ export default function Main({ match }) {
await api.post(`devs/${targetID}/likes`, null, {
headers: { user: id },
});

setUsers(users.filter(user => user._id !== targetID));
}

async function handleDisLike(targetID) {
await api.post(`devs/${targetID}/dislikes`, null, {
headers: { user: id },
});

setUsers(users.filter(user => user._id !== targetID));
}

return (
Expand Down

0 comments on commit 795475f

Please sign in to comment.