minor code cleanups
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
parent
7fcd160911
commit
e3fe848c6b
@ -1,4 +1,4 @@
|
||||
# Copyright (C) 2003-2015 John Goerzen & contributors
|
||||
# Copyright (C) 2003-2016 John Goerzen & contributors
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@ -20,6 +20,7 @@ import os
|
||||
import time
|
||||
from sys import exc_info
|
||||
import traceback
|
||||
import six
|
||||
|
||||
from offlineimap import mbnames, CustomConfig, OfflineImapError
|
||||
from offlineimap import globals
|
||||
@ -27,8 +28,6 @@ from offlineimap.repository import Repository
|
||||
from offlineimap.ui import getglobalui
|
||||
from offlineimap.threadutil import InstanceLimitedThread
|
||||
|
||||
import six
|
||||
|
||||
FOLDER_NAMESPACE = 'LIMITED_FOLDER_'
|
||||
|
||||
try:
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Maildir folder support
|
||||
# Copyright (C) 2002-2015 John Goerzen & contributors
|
||||
# Copyright (C) 2002-2016 John Goerzen & contributors
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@ -19,11 +19,10 @@ import socket
|
||||
import time
|
||||
import re
|
||||
import os
|
||||
from sys import exc_info
|
||||
from .Base import BaseFolder
|
||||
from threading import Lock
|
||||
|
||||
import six
|
||||
from sys import exc_info
|
||||
from threading import Lock
|
||||
from .Base import BaseFolder
|
||||
|
||||
try:
|
||||
from hashlib import md5
|
||||
|
@ -146,8 +146,7 @@ class MaildirRepository(BaseRepository):
|
||||
if foldername == f.name:
|
||||
return f
|
||||
raise OfflineImapError("getfolder() asked for a nonexisting "
|
||||
"folder '%s'."% foldername,
|
||||
OfflineImapError.ERROR.FOLDER)
|
||||
"folder '%s'."% foldername, OfflineImapError.ERROR.FOLDER)
|
||||
|
||||
def _getfolders_scandir(self, root, extension=None):
|
||||
"""Recursively scan folder 'root'; return a list of MailDirFolder
|
||||
|
Loading…
Reference in New Issue
Block a user