Skip to content

Commit

Permalink
fix: add csv to supported file type uploads
Browse files Browse the repository at this point in the history
  • Loading branch information
aalemayhu committed Sep 15, 2023
1 parent b82f32c commit c03b810
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/usecases/uploads/GeneratePackagesUseCase.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import Package from '../../lib/parser/Package';
import Settings from '../../lib/parser/Settings';
import StorageHandler from '../../lib/storage/StorageHandler';
import {
isCSVFile,
isHTMLFile,
isMarkdownFile,
isPlainText,
Expand All @@ -20,7 +21,10 @@ export interface PackageResult {
}

export const isFileSupported = (filename: string) =>
isHTMLFile(filename) ?? isMarkdownFile(filename) ?? isPlainText(filename);
isHTMLFile(filename) ??
isMarkdownFile(filename) ??
isPlainText(filename) ??
isCSVFile(filename);

const getPackagesFromZip = async (
fileContents: Body | undefined,
Expand Down

0 comments on commit c03b810

Please sign in to comment.