Show
Ignore:
Timestamp:
05/05/10 14:05:39 (2 years ago)
Author:
Menno Smits <menno@…>
Branch:
default
Message:

Always return folder names as unicode for consistency.

Otherwise sometimes the folder names are unicode and sometimes they
are strs. This is good practice for Python 3.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • imapclient/imap_utf7.py

    r147 r148  
    7171    if decode: 
    7272        r.append(modified_unbase64(''.join(decode[1:]))) 
    73     return ''.join(r) 
     73    out = ''.join(r) 
     74 
     75    if not isinstance(out, unicode): 
     76        out = unicode(out, 'latin-1') 
     77    return out 
    7478 
    7579