refactor: clean up unused imports and improve code readability and fixed endpoint to use window location
This commit is contained in:
@@ -2,6 +2,7 @@ import { useFormikContext } from "formik";
|
||||
import FormGroup from "../components/FormGroup";
|
||||
import { toast } from "sonner";
|
||||
import { useSystemConfig } from "../../../hooks/useSystemConfig";
|
||||
import { CAM_BASE } from "../../../utils/config";
|
||||
|
||||
type SystemFileUploadProps = {
|
||||
name: string;
|
||||
@@ -19,7 +20,7 @@ const SystemFileUpload = ({ name, selectedFile }: SystemFileUploadProps) => {
|
||||
opts: {
|
||||
timeoutMs: 30000,
|
||||
fieldName: "upload",
|
||||
uploadUrl: "http://192.168.75.11/upload/software-update/4",
|
||||
uploadUrl: `${CAM_BASE}/upload/software-update/4`,
|
||||
},
|
||||
};
|
||||
uploadSettings(settings);
|
||||
|
||||
Reference in New Issue
Block a user