From 14dafa9a8ad909f0c48e2b3b113c6cdab26013bd Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Wed, 5 Nov 2025 06:27:27 +0000 Subject: [PATCH] [autofix.ci] apply automated fixes --- .../docker/upload/upload-file-modal.tsx | 20 +++++-------------- apps/dokploy/utils/schema.ts | 5 ++++- 2 files changed, 9 insertions(+), 16 deletions(-) diff --git a/apps/dokploy/components/dashboard/docker/upload/upload-file-modal.tsx b/apps/dokploy/components/dashboard/docker/upload/upload-file-modal.tsx index 98194f801..183241726 100644 --- a/apps/dokploy/components/dashboard/docker/upload/upload-file-modal.tsx +++ b/apps/dokploy/components/dashboard/docker/upload/upload-file-modal.tsx @@ -36,11 +36,7 @@ interface Props { children?: React.ReactNode; } -export const UploadFileModal = ({ - children, - containerId, - serverId, -}: Props) => { +export const UploadFileModal = ({ children, containerId, serverId }: Props) => { const [open, setOpen] = useState(false); const { mutateAsync: uploadFile, isLoading } = @@ -51,9 +47,7 @@ export const UploadFileModal = ({ form.reset(); }, onError: (error) => { - toast.error( - error.message || "Failed to upload file to container", - ); + toast.error(error.message || "Failed to upload file to container"); }, }); @@ -107,10 +101,7 @@ export const UploadFileModal = ({
- +

- Enter the full path where the file should be - uploaded in the container (e.g., /app/config.json) + Enter the full path where the file should be uploaded in the + container (e.g., /app/config.json)

)} @@ -194,4 +185,3 @@ export const UploadFileModal = ({ ); }; - diff --git a/apps/dokploy/utils/schema.ts b/apps/dokploy/utils/schema.ts index 47d99f6cc..73df59d6f 100644 --- a/apps/dokploy/utils/schema.ts +++ b/apps/dokploy/utils/schema.ts @@ -19,7 +19,10 @@ export const uploadFileSchema = zfd.formData({ export type UploadFile = z.infer; export const uploadFileToContainerSchema = zfd.formData({ - containerId: z.string().min(1).regex(/^[a-zA-Z0-9.\-_]+$/, "Invalid container ID"), + containerId: z + .string() + .min(1) + .regex(/^[a-zA-Z0-9.\-_]+$/, "Invalid container ID"), file: zfd.file(), destinationPath: z.string().min(1), serverId: z.string().optional(),