From 87fc7b39cc30ba2984d8530fdcb512696c7e9a5e Mon Sep 17 00:00:00 2001 From: Francis Lachapelle Date: Wed, 11 Nov 2015 16:01:37 -0500 Subject: [PATCH] Handle ExpandedFolders settings from v2 --- UI/MailerUI/UIxMailMainFrame.m | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/UI/MailerUI/UIxMailMainFrame.m b/UI/MailerUI/UIxMailMainFrame.m index bc5d6930f..99ce6edc7 100644 --- a/UI/MailerUI/UIxMailMainFrame.m +++ b/UI/MailerUI/UIxMailMainFrame.m @@ -328,12 +328,17 @@ - (WOResponse *) getFoldersStateAction { - NSString *expandedFolders; + id o; + NSArray *expandedFolders; [self _setupContext]; - expandedFolders = [moduleSettings objectForKey: @"ExpandedFolders"]; + o = [moduleSettings objectForKey: @"ExpandedFolders"]; + if ([o isKindOfClass: [NSString class]]) + expandedFolders = [o componentsSeparatedByString: @","]; + else + expandedFolders = o; - return [self responseWithStatus: 200 andString: expandedFolders]; + return [self responseWithStatus: 200 andJSONRepresentation: expandedFolders]; } - (NSString *) verticalDragHandleStyle