From 4ad6e452163c9fba6328e2baf4b7d22da63a6a77 Mon Sep 17 00:00:00 2001 From: ed Date: Sun, 5 Feb 2023 00:01:10 +0000 Subject: [PATCH] only load *.conf files when including a folder --- copyparty/authsrv.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/copyparty/authsrv.py b/copyparty/authsrv.py index f03816ac..364207e5 100644 --- a/copyparty/authsrv.py +++ b/copyparty/authsrv.py @@ -1515,8 +1515,8 @@ def expand_config_file(ret: list[str], fp: str, ipath: str) -> None: if os.path.isdir(fp): for fn in sorted(os.listdir(fp)): fp2 = os.path.join(fp, fn) - if not os.path.isfile(fp2): - continue # dont recurse + if not fp2.endswith(".conf") or fp in ipath: + continue expand_config_file(ret, fp2, ipath) return