Skip to content
Snippets Groups Projects
Unverified Commit 45f50ce1 authored by Sean Hatfield's avatar Sean Hatfield Committed by GitHub
Browse files

[FIX] Update metadata tags in PDF collector script (#925)

update title in pdf collector script to be the filename instead of metadata title
parent 568e78d3
No related branches found
No related tags found
No related merge requests found
...@@ -40,9 +40,9 @@ async function asPDF({ fullFilePath = "", filename = "" }) { ...@@ -40,9 +40,9 @@ async function asPDF({ fullFilePath = "", filename = "" }) {
const data = { const data = {
id: v4(), id: v4(),
url: "file://" + fullFilePath, url: "file://" + fullFilePath,
title: docs[0]?.metadata?.pdf?.info?.Title || filename, title: filename,
docAuthor: docs[0]?.metadata?.pdf?.info?.Creator || "no author found", docAuthor: docs[0]?.metadata?.pdf?.info?.Creator || "no author found",
description: "No description found.", description: docs[0]?.metadata?.pdf?.info?.Title || "No description found.",
docSource: "pdf file uploaded by the user.", docSource: "pdf file uploaded by the user.",
chunkSource: "", chunkSource: "",
published: createdDate(fullFilePath), published: createdDate(fullFilePath),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment