From a083dc36bafe791be79f739dbd93ecbb811ff117 Mon Sep 17 00:00:00 2001 From: ed Date: Fri, 27 Jan 2023 20:27:00 +0000 Subject: [PATCH] dont get confused by dangling symlinks at target --- copyparty/util.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/copyparty/util.py b/copyparty/util.py index aab7ed78..8cf0110c 100644 --- a/copyparty/util.py +++ b/copyparty/util.py @@ -1193,7 +1193,7 @@ def ren_open( else: fpath = fname - if suffix and os.path.exists(fsenc(fpath)): + if suffix and os.path.lexists(fsenc(fpath)): fpath += suffix fname += suffix ext += suffix