Fix: dont allow archive version for share links when one doesnt exist (#13163)

This commit is contained in:
shamoon authored and GitHub committed 2026-07-19 20:54:58 +00:00
1 parent 2180b21c41
commit 4f6d9fa93f
2 files changed
+45 -1

No files matched your search

+2 -1
View File
@@ -4534,7 +4534,8 @@ class SharedLinkView(View):
return HttpResponseRedirect("/accounts/login/?sharelink_expired=1")
return serve_file(
doc=share_link.document,
use_archive=share_link.file_version == "archive",
use_archive=share_link.file_version == ShareLink.FileVersion.ARCHIVE
and share_link.document.has_archive_version,
disposition="inline",
)