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
|
# 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
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -20,6 +20,7 @@ import os
|
|||||||
import time
|
import time
|
||||||
from sys import exc_info
|
from sys import exc_info
|
||||||
import traceback
|
import traceback
|
||||||
|
import six
|
||||||
|
|
||||||
from offlineimap import mbnames, CustomConfig, OfflineImapError
|
from offlineimap import mbnames, CustomConfig, OfflineImapError
|
||||||
from offlineimap import globals
|
from offlineimap import globals
|
||||||
@ -27,8 +28,6 @@ from offlineimap.repository import Repository
|
|||||||
from offlineimap.ui import getglobalui
|
from offlineimap.ui import getglobalui
|
||||||
from offlineimap.threadutil import InstanceLimitedThread
|
from offlineimap.threadutil import InstanceLimitedThread
|
||||||
|
|
||||||
import six
|
|
||||||
|
|
||||||
FOLDER_NAMESPACE = 'LIMITED_FOLDER_'
|
FOLDER_NAMESPACE = 'LIMITED_FOLDER_'
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
# Maildir folder support
|
# 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
|
# 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
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -19,11 +19,10 @@ import socket
|
|||||||
import time
|
import time
|
||||||
import re
|
import re
|
||||||
import os
|
import os
|
||||||
from sys import exc_info
|
|
||||||
from .Base import BaseFolder
|
|
||||||
from threading import Lock
|
|
||||||
|
|
||||||
import six
|
import six
|
||||||
|
from sys import exc_info
|
||||||
|
from threading import Lock
|
||||||
|
from .Base import BaseFolder
|
||||||
|
|
||||||
try:
|
try:
|
||||||
from hashlib import md5
|
from hashlib import md5
|
||||||
|
@ -146,8 +146,7 @@ class MaildirRepository(BaseRepository):
|
|||||||
if foldername == f.name:
|
if foldername == f.name:
|
||||||
return f
|
return f
|
||||||
raise OfflineImapError("getfolder() asked for a nonexisting "
|
raise OfflineImapError("getfolder() asked for a nonexisting "
|
||||||
"folder '%s'."% foldername,
|
"folder '%s'."% foldername, OfflineImapError.ERROR.FOLDER)
|
||||||
OfflineImapError.ERROR.FOLDER)
|
|
||||||
|
|
||||||
def _getfolders_scandir(self, root, extension=None):
|
def _getfolders_scandir(self, root, extension=None):
|
||||||
"""Recursively scan folder 'root'; return a list of MailDirFolder
|
"""Recursively scan folder 'root'; return a list of MailDirFolder
|
||||||
|
Loading…
Reference in New Issue
Block a user