From eacf0f7209538afce58db721a0d9f79c7e368555 Mon Sep 17 00:00:00 2001 From: SethBurkart123 Date: Tue, 5 Dec 2023 07:14:42 +1100 Subject: [PATCH] improve types of fileUpload --- src/seqta/utils/FileUpload.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/seqta/utils/FileUpload.ts b/src/seqta/utils/FileUpload.ts index 339b0c0c..d319f482 100644 --- a/src/seqta/utils/FileUpload.ts +++ b/src/seqta/utils/FileUpload.ts @@ -1,11 +1,11 @@ /** * Uploads an image file to a specified endpoint using a POST request. * - * @param {File} file - The image file to be uploaded. + * @param {File} file - The file to be uploaded. * @returns {Promise} A promise that resolves to the response from the server. * @throws {Error} If no file is provided or if there is an error during upload. */ -export async function UploadImage(file: any) { +export async function UploadImage(file: File): Promise { // Ensuring that file is provided if (!file) { throw new Error("No file provided");