removed auth header
This commit is contained in:
parent
e7e23549f7
commit
3b6e8e1aac
@ -84,9 +84,6 @@ export const api: AxiosInstance = axios.create({
|
|||||||
export function ApiWrapper(p: { children: ReactNode}) {
|
export function ApiWrapper(p: { children: ReactNode}) {
|
||||||
const {children} = p
|
const {children} = p
|
||||||
const token = Cookies.get('auth')
|
const token = Cookies.get('auth')
|
||||||
if (token) {
|
|
||||||
api.defaults.headers.common.Authorization = `Bearer ${token}`;
|
|
||||||
}
|
|
||||||
|
|
||||||
const [apiAuthenticated, setApiAuthenticated] = useState(Boolean(token))
|
const [apiAuthenticated, setApiAuthenticated] = useState(Boolean(token))
|
||||||
if (!apiAuthenticated) {
|
if (!apiAuthenticated) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user