mirror of
https://github.com/stonith404/pingvin-share.git
synced 2025-01-15 01:14:27 -05:00
fix: my shares doesn't make an api request
This commit is contained in:
parent
a50d16dcff
commit
247ce92744
2 changed files with 5 additions and 5 deletions
|
@ -1,8 +1,8 @@
|
|||
backend/dist/
|
||||
backend/node_modules/
|
||||
backend/data
|
||||
|
||||
frontend/node_modules/
|
||||
frontend/.next/
|
||||
frontend/dist/
|
||||
|
||||
**/.git/
|
||||
|
|
|
@ -15,7 +15,7 @@ import { useModals } from "@mantine/modals";
|
|||
import { NextLink } from "@mantine/next";
|
||||
import moment from "moment";
|
||||
import { useRouter } from "next/router";
|
||||
import { useState } from "react";
|
||||
import { useEffect, useState } from "react";
|
||||
import { Link, Trash } from "tabler-icons-react";
|
||||
import Meta from "../../components/Meta";
|
||||
import useUser from "../../hooks/user.hook";
|
||||
|
@ -31,9 +31,9 @@ const MyShares = () => {
|
|||
|
||||
const [shares, setShares] = useState<MyShare[]>();
|
||||
|
||||
// useEffect(() => {
|
||||
// shareService.getMyShares().then((shares) => setShares(shares));
|
||||
// }, []);
|
||||
useEffect(() => {
|
||||
shareService.getMyShares().then((shares) => setShares(shares));
|
||||
}, []);
|
||||
|
||||
if (!user) {
|
||||
router.replace("/");
|
||||
|
|
Loading…
Reference in a new issue