From f2d2268039994f94a100933108618d98778cd7a7 Mon Sep 17 00:00:00 2001 From: ZareMate <0.zaremate@gmail.com> Date: Sun, 4 May 2025 19:10:22 +0200 Subject: [PATCH] refactor: remove local getFileType function and use imported utility --- src/app/_components/FilePreview.tsx | 30 +---------------------------- 1 file changed, 1 insertion(+), 29 deletions(-) diff --git a/src/app/_components/FilePreview.tsx b/src/app/_components/FilePreview.tsx index 670d175..119e0cd 100644 --- a/src/app/_components/FilePreview.tsx +++ b/src/app/_components/FilePreview.tsx @@ -1,6 +1,7 @@ "use client"; import { useEffect, useState } from "react"; +import { getFileType } from "~/utils/fileType"; // Adjust the import path as necessary interface FilePreviewProps { fileId: string; @@ -51,35 +52,6 @@ export function FilePreview({ fileId, fileType }: FilePreviewProps) { if (!mediaSrc) { return