[tor-commits] [stem/master] Improve almost duplicate code into for-loop

atagar at torproject.org atagar at torproject.org
Thu Apr 2 00:11:48 UTC 2020


commit 59da1120f234b9c7c8f7a92e339693105da25fe7
Author: msramalho <up201403027 at fe.up.pt>
Date:   Mon Mar 30 21:54:47 2020 +0100

    Improve almost duplicate code into for-loop
---
 setup.py | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/setup.py b/setup.py
index 8e738a20..968e42c0 100644
--- a/setup.py
+++ b/setup.py
@@ -153,8 +153,6 @@ try:
     ],
   )
 finally:
-  if os.path.exists('MANIFEST.in'):
-    os.remove('MANIFEST.in')
-
-  if os.path.exists('MANIFEST'):
-    os.remove('MANIFEST')
+  for filename in ['MANIFEST.in', 'MANIFEST']:
+    if os.path.exists(filename):
+      os.remove(filename)





More information about the tor-commits mailing list