diff --git a/src/game_pages/detail/components/StickyBottom/index.tsx b/src/game_pages/detail/components/StickyBottom/index.tsx index df270b6..40ec7ad 100644 --- a/src/game_pages/detail/components/StickyBottom/index.tsx +++ b/src/game_pages/detail/components/StickyBottom/index.tsx @@ -20,9 +20,11 @@ function isFull(counts) { current_substitute_count, is_substitute_supported, } = counts; - if (max_players === current_players) { + + if (max_players === current_players &&is_substitute_supported === IsSubstituteSupported.NOTSUPPORT) { return true; - } else if (is_substitute_supported === IsSubstituteSupported.SUPPORT) { + } + else if (max_players === current_players &&is_substitute_supported === IsSubstituteSupported.SUPPORT) { return max_substitute_players === current_substitute_count; } @@ -111,6 +113,7 @@ export default function StickyButton(props) { is_substituting, waiting_start, } = user_action_status || {}; + if (MATCH_STATUS.CANCELED === match_status) { return { text: "活动已取消", diff --git a/src/home_pages/index.tsx b/src/home_pages/index.tsx index b6ab81d..25a8fe8 100644 --- a/src/home_pages/index.tsx +++ b/src/home_pages/index.tsx @@ -7,6 +7,7 @@ import "./index.scss"; const HomePage: React.FC = () => { const { fetchUserInfo } = useUserActions(); + useEffect(() => { const handleLoginRedirect = async () => { const login_status = check_login_status();