From f6c2b1129de3bc96ede60b60dd60166e388879a8 Mon Sep 17 00:00:00 2001 From: "CHIEFSOFT\\ameye" Date: Sun, 28 Dec 2025 14:34:21 -0500 Subject: [PATCH] server path --- src/component/mymedia/MyMedia.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/component/mymedia/MyMedia.js b/src/component/mymedia/MyMedia.js index 7570a52..aff659f 100644 --- a/src/component/mymedia/MyMedia.js +++ b/src/component/mymedia/MyMedia.js @@ -3,7 +3,7 @@ import BreadcrumbComBS from "../breadcrumb/BreadcrumbComBS"; import {useState, useRef} from "react"; export default function MyMedia() { - + const basePath = process.env.REACT_APP_MAIN_API const [selectedFile, setSelectedFile] = useState(null); const [message, setMessage] = useState(''); @@ -28,7 +28,7 @@ export default function MyMedia() { try { // Replace with your actual API endpoint URL - const apiEndpoint = 'https://devapi.mermsemr.com/upload/webfiles'; + const apiEndpoint = basePath + '/upload/webfiles'; const response = await fetch(apiEndpoint, { method: 'POST', // The browser automatically sets the 'Content-Type' header to