[PATCH] folder/Base.py: No need to import InstanceLimitedThread explicitely

Sebastian Spaeth Sebastian at SSpaeth.de
Mon Jan 10 09:02:21 GMT 2011


We already import threadutil, so no need to also import
threadutil.InstanceLimitedThread separately.

Signed-off-by: Sebastian Spaeth <Sebastian at SSpaeth.de>
---
This is based against current master and is a minor cleanup. Take it or
leave it :-)

 offlineimap/folder/Base.py |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/offlineimap/folder/Base.py b/offlineimap/folder/Base.py
index 0f38bc3..3843c1b 100644
--- a/offlineimap/folder/Base.py
+++ b/offlineimap/folder/Base.py
@@ -18,9 +18,9 @@
 
 from threading import *
 from offlineimap import threadutil
-from offlineimap.threadutil import InstanceLimitedThread
 from offlineimap.ui import UIBase
-import os.path, re
+import os.path
+import re
 import sys
 
 class BaseFolder:
@@ -248,7 +248,7 @@ class BaseFolder:
         for uid in uidlist:
             if usethread and usethread.suggeststhreads():
                 usethread.waitforthread()
-                thread = InstanceLimitedThread(\
+                thread = threadutil.InstanceLimitedThread(\
                     usethread.getcopyinstancelimit(),
                     target = self.syncmessagesto_neguid_msg,
                     name = "New msg sync from %s" % self.getvisiblename(),
@@ -307,7 +307,7 @@ class BaseFolder:
             if not uid in dest_messagelist:
                 if self.suggeststhreads():
                     self.waitforthread()
-                    thread = InstanceLimitedThread(\
+                    thread = threadutil.InstanceLimitedThread(\
                         self.getcopyinstancelimit(),
                         target = self.copymessageto,
                         name = "Copy message %d from %s" % (uid,
-- 
1.7.1





More information about the OfflineIMAP-project mailing list