IMAP cachefolder: Fix returning None on select
We rely on the number of mails being returned by the imapobj.select() call, however that only happens if we "force" a real select() to occur. Pass in the force parameter that I dropped earlier (we did not make use of the return value when I dropped it, that is how it slipped through). Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de> Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
parent
24db42916c
commit
7c83d505f8
@ -120,7 +120,7 @@ class IMAPFolder(BaseFolder):
|
||||
|
||||
imapobj = self.imapserver.acquireconnection()
|
||||
try:
|
||||
res_type, imapdata = imapobj.select(self.getfullname(), True)
|
||||
res_type, imapdata = imapobj.select(self.getfullname(), True, True)
|
||||
if imapdata == [None] or imapdata[0] == '0':
|
||||
# Empty folder, no need to populate message list
|
||||
return
|
||||
|
Loading…
Reference in New Issue
Block a user