From 30fc17a540abe6daf1b875f783a1ecd61d22b858 Mon Sep 17 00:00:00 2001 From: Maximun Date: Tue, 17 Mar 2026 19:51:51 +0530 Subject: [PATCH] Oopsie dupsie :> idon'tknowhyididthis;-; --- copyparty/svchub.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/copyparty/svchub.py b/copyparty/svchub.py index 0778d261..4bb7a2e8 100644 --- a/copyparty/svchub.py +++ b/copyparty/svchub.py @@ -1373,7 +1373,7 @@ class SvcHub(object): lh = codecs.open(fn, "w", encoding="utf-8", errors="replace") # Patch the opened log file write method - orig_w = getattr(lh, "write") + orig_w = lh.write def patched_write(data: str): try: @@ -1382,8 +1382,7 @@ class SvcHub(object): clean = data return orig_w(clean) - setattr(lh, "write", patched_write) - # lh.write = patched_write #type: ignore + lh.write = patched_write #type: ignore if getattr(self.args, "free_umask", False): os.fchmod(lh.fileno(), 0o644)