Skip to content

Commit

Permalink
Fix: 서버 요청에 유저 인증 토큰값을 넣어 보내기 위해 axios -> authAPI 로 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
pp449 committed Sep 26, 2023
1 parent 2dc1ddc commit 8ce6a2c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/components/Modal/JoinLeague/JoinLeague.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { SERVER_URL } from '@config/index';
import { css } from '@emotion/react';
import styled from '@emotion/styled';
import useProfile from '@hooks/useProfile';
import axios from 'axios';
import { useState, MouseEventHandler, useEffect, useRef } from 'react';

interface JoinLeagueProps {
Expand All @@ -27,7 +26,7 @@ const JoinLeague = ({ onClose, channelLink }: JoinLeagueProps) => {
return;
}
const userTier: string = (
await axios.get(SERVER_URL + '/api/participant/stat?gameid=' + gameIdVal)
await authAPI.get(SERVER_URL + '/api/participant/stat?gameid=' + gameIdVal)
).data.tier;
setTier(userTier);
setGameId(gameIdVal);
Expand Down

0 comments on commit 8ce6a2c

Please sign in to comment.