Skip to content

Commit

Permalink
refactor: 移除 user-slice (已使用 useUser 取代)
Browse files Browse the repository at this point in the history
  • Loading branch information
AndrewCK24 committed Jun 19, 2024
1 parent e1fd1e8 commit f2bc66d
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 51 deletions.
46 changes: 0 additions & 46 deletions app/(protected)/user/user-slice.js

This file was deleted.

2 changes: 0 additions & 2 deletions app/store/store.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
import { configureStore } from "@reduxjs/toolkit";

import userReducer from "../(protected)/user/user-slice";
import lineupsReducer from "@/app/store/lineups-slice";
import matchReducer from "../match/match-slice";

const store = configureStore({
reducer: {
user: userReducer,
lineups: lineupsReducer,
match: matchReducer,
},
Expand Down
3 changes: 0 additions & 3 deletions hooks/use-data.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,6 @@ export const useTeamMembers = (
fetcher = defaultFetcher,
options = {}
) => {
// TODO: 新增 conditional fetching
// if (!teamId) teamId = useSelector((state) => state.user.teams.joined[0]);

const { data, error, isLoading, isValidating, mutate } = useSWR(
`/api/teams/${teamId}/members`,
fetcher,
Expand Down

0 comments on commit f2bc66d

Please sign in to comment.