diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2020-09-03 10:37:11 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2021-02-28 12:15:20 +0100 |
commit | c9e6ef1bc313169a91abe1df0564ccd8f46358d2 (patch) | |
tree | 7003e5bd29cdb0313f1d08e8d5793cf579e9e292 /ishtar_common | |
parent | 735be2a425636b7dc49f71c650e1765a527a3e97 (diff) | |
download | Ishtar-c9e6ef1bc313169a91abe1df0564ccd8f46358d2.tar.bz2 Ishtar-c9e6ef1bc313169a91abe1df0564ccd8f46358d2.zip |
Fix document symlink error
Diffstat (limited to 'ishtar_common')
-rw-r--r-- | ishtar_common/models.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/ishtar_common/models.py b/ishtar_common/models.py index 04ed6d6c0..d26a64e38 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -5779,7 +5779,10 @@ class Document(BaseHistorizedItem, QRCodeItem, OwnPerms, ImageModel, links.append(new_path) if match: # the current link is correct continue - os.symlink(reference_path, new_path) + try: + os.symlink(reference_path, new_path) + except FileExistsError: + pass return links def related_label(self): |