Skip to content

Commit

Permalink
with working patched mmagic
Browse files Browse the repository at this point in the history
  • Loading branch information
adhityan committed Jun 13, 2024
1 parent 2c47523 commit b2efef3
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
"mime": "^4.0.3",
"office-text-extractor": "^3.0.3",
"sitemapper": "^3.1.8",
"stream-mmmagic-patched": "^2.4.1",
"stream-mmmagic-patched": "^2.4.2",
"usetube": "^2.0.2",
"uuid": "^10.0.0",
"youtube-transcript": "^1.2.1"
Expand Down
2 changes: 2 additions & 0 deletions src/util/mime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ export async function createLoaderFromMimeType(loader: string, mimeType: string)
createDebugMessages('embedjs:createLoaderFromMimeType')(`Fine type for '${loader}' is '${fineType}'`);
if (fineType === 'text/csv') return new CsvLoader({ filePathOrUrl: loader });
else return new TextLoader({ text: loader });
case 'application/csv':
return new CsvLoader({ filePathOrUrl: loader });
case 'text/html':
return new WebLoader({ urlOrContent: loader });
case 'text/xml':
Expand Down

0 comments on commit b2efef3

Please sign in to comment.