mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-07-05 16:35:10 +00:00
Small fix for servers that don't have NAMESPACE
Monotone-Parent: 5de6a9584cf27a2c1dad8d1ab8b84fc9ddab2720 Monotone-Revision: 8fb65e4ddd95ab6be36dc4834118f0f4c9e565bc Monotone-Author: ludovic@Sophos.ca Monotone-Date: 2011-04-26T13:10:40 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
@@ -95,8 +95,10 @@
|
||||
ASSIGN(draftsFolderName, [specialFolders objectAtIndex: 1]);
|
||||
ASSIGN(sentFolderName, [specialFolders objectAtIndex: 2]);
|
||||
ASSIGN(trashFolderName, [specialFolders objectAtIndex: 3]);
|
||||
ASSIGN(otherUsersFolderName, [specialFolders objectAtIndex: 4]);
|
||||
ASSIGN(sharedFoldersName, [specialFolders objectAtIndex: 5]);
|
||||
if ([specialFolders count] == 5)
|
||||
ASSIGN(otherUsersFolderName, [specialFolders objectAtIndex: 4]);
|
||||
if ([specialFolders count] == 6)
|
||||
ASSIGN(sharedFoldersName, [specialFolders objectAtIndex: 5]);
|
||||
}
|
||||
|
||||
if ([folderName isEqualToString: inboxFolderName])
|
||||
@@ -129,7 +131,7 @@
|
||||
// We translate the "Other Users" and "Shared Folders" namespaces.
|
||||
// While we're at it, we also translate the user's mailbox names
|
||||
// to the full name of the person.
|
||||
if ([currentFolder hasPrefix: otherUsersFolderName])
|
||||
if (otherUsersFolderName && [currentFolder hasPrefix: otherUsersFolderName])
|
||||
{
|
||||
// We have a string like /Other Users/lmarcotte/...
|
||||
pathComponents = [NSMutableArray arrayWithArray: [currentFolder pathComponents]];
|
||||
@@ -144,7 +146,7 @@
|
||||
[pathComponents componentsJoinedByString: @"/"]];
|
||||
|
||||
}
|
||||
else if ([currentFolder hasPrefix: sharedFoldersName])
|
||||
else if (sharedFoldersName && [currentFolder hasPrefix: sharedFoldersName])
|
||||
currentDisplayName = [NSString stringWithFormat: @"/%@%@", [self labelForKey: @"SharedFoldersName"],
|
||||
[currentFolder substringFromIndex: [sharedFoldersName length]]];
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user