Skip to content

Commit

Permalink
remove test sendmail func
Browse files Browse the repository at this point in the history
  • Loading branch information
NwinNwin committed Aug 14, 2023
1 parent e0b0c9f commit fc352df
Showing 1 changed file with 0 additions and 23 deletions.
23 changes: 0 additions & 23 deletions src/components/Home/Home.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -150,20 +150,6 @@ export default function Home() {
setScreenWidth(window.screen.width);
};

// send email
function sendMail() {
let userEmail = user.email;
if (user) {
axios
.post(`${process.env.REACT_APP_AWS_BACKEND_URL}/send_email`, {
userEmail,
})
.then(() => alert("Email Sent Successfully!"))
.catch(() => alert("Email NOT SENT"));
}
return;
}

return (
<DataContext.Provider
value={{
Expand Down Expand Up @@ -257,15 +243,6 @@ export default function Home() {
onChange={(e) => setSearch(e.target.value)}
/>
</InputGroup>
{user && (
<Button
onClick={() => {
sendMail();
}}
>
send email to YOU
</Button>
)}
</HStack>

<Flex alignItems="center" justifyContent="space-between" mr={7} gap={5}>
Expand Down

0 comments on commit fc352df

Please sign in to comment.