main
mula.liu 2026-05-11 09:48:19 +08:00
parent 1fe3508ec6
commit ccb61b00fa
1 changed files with 2 additions and 1 deletions

View File

@ -474,6 +474,7 @@ async def get_project_share_file(
ensure_share_access(share, request, password)
file_path = storage_service.get_secure_path(project.storage_key, path)
content = await storage_service.read_file(file_path)
content = rewrite_markdown_assets(content, f"/api/v1/shares/project/{share.share_code}/assets")
return success_response(data={"content": content})
@ -573,7 +574,7 @@ async def get_file_share_content(
})
content = await storage_service.read_file(file_path)
content = rewrite_markdown_assets_for_pdf(content)
content = rewrite_markdown_assets(content, f"/api/v1/shares/files/{share.share_code}/assets")
return success_response(data={
"type": "markdown",
"filename": Path(share.file_path).name,