fix: Extract docx file fails when the file contains an invalid link (#17576)

This commit is contained in:
Steven Li authored and GitHub committed 2025-04-08 13:59:33 +08:00
1 parent 07ed728605
commit abead647e2
1 file changed
+1 -1
+1 -1
View File
@@ -85,7 +85,7 @@ class WordExtractor(BaseExtractor):
if "image" in rel.target_ref:
image_count += 1
if rel.is_external:
url = rel.reltype
url = rel.target_ref
response = ssrf_proxy.get(url)
if response.status_code == 200:
image_ext = mimetypes.guess_extension(response.headers["Content-Type"])