From f631fb3116b80b88a16d903dadcf5a4aab9da274 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Thu, 14 Jun 2007 20:01:22 +0000 Subject: [PATCH] Delete torrent's files correctly now. --- src/core.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/core.py b/src/core.py index c80c14ae6..65fc9c609 100644 --- a/src/core.py +++ b/src/core.py @@ -319,12 +319,11 @@ class Manager: shutil.rmtree(os.path.dirname(os.path.join(temp.save_dir, filename))) except OSError: # Perhaps it wasn't downloaded pass - else: - # This is just a file - try: - os.remove(os.path.join(temp.save_dir, filename)) - except OSError: - pass # No file just means it wasn't downloaded, we can continue + # Perhaps this is just a file, try to remove it + try: + os.remove(os.path.join(temp.save_dir, filename)) + except OSError: + pass # No file just means it wasn't downloaded, we can continue ### UNNEEDED, fixed already above # # Clean up empty dir