From fd5294ed82a86ea9b122f549a2154b5ee6335846 Mon Sep 17 00:00:00 2001 From: Dan Brown Date: Sat, 9 Mar 2024 21:49:15 +0100 Subject: [PATCH] Fix broken link when specified in metadata (#1200) --- backend/danswer/connectors/file/connector.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/danswer/connectors/file/connector.py b/backend/danswer/connectors/file/connector.py index 8296735f9..d756b7d29 100644 --- a/backend/danswer/connectors/file/connector.py +++ b/backend/danswer/connectors/file/connector.py @@ -98,7 +98,7 @@ def _process_file( Document( id=f"FILE_CONNECTOR__{file_name}", # add a prefix to avoid conflicts with other connectors sections=[ - Section(link=metadata.get("link"), text=file_content_raw.strip()) + Section(link=file_metadata.get("link"), text=file_content_raw.strip()) ], source=DocumentSource.FILE, semantic_identifier=file_display_name_override or file_name,