From 648301bce052836999c8608c02cd06591ec443b3 Mon Sep 17 00:00:00 2001 From: Vin Bui Date: Fri, 13 Dec 2024 22:59:21 -0500 Subject: [PATCH] Fix env --- src/services/apiClient.ts | 3 +-- src/utils/constants.ts | 3 --- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/src/services/apiClient.ts b/src/services/apiClient.ts index a44dedd..99a5ceb 100644 --- a/src/services/apiClient.ts +++ b/src/services/apiClient.ts @@ -1,4 +1,3 @@ -import { Constants } from "@/utils/constants"; import axios, { AxiosInstance, AxiosRequestConfig, AxiosResponse } from "axios"; /** @@ -43,7 +42,7 @@ class ApiClient { */ static createInstance(): AxiosInstance { return axios.create({ - baseURL: Constants.api.baseUrl, + baseURL: process.env.NEXT_PUBLIC_API_BASE_URL, headers: { "Content-Type": "application/json", }, diff --git a/src/utils/constants.ts b/src/utils/constants.ts index 249348a..bbf9425 100644 --- a/src/utils/constants.ts +++ b/src/utils/constants.ts @@ -2,9 +2,6 @@ * A collection of constant values used throughout the application. */ export const Constants = { - api: { - baseUrl: process.env.NEXT_PUBLIC_API_BASE_URL || "http://localhost:8000", - }, pagePath: { default: "/", landing: "/landing",