Commit 1256d81d authored by Jim Nelson's avatar Jim Nelson

Fixes IMAP error causing all remote folders to be considered deleted

parent 9197dffb
......@@ -360,8 +360,8 @@ private abstract class Geary.ImapEngine.GenericAccount : Geary.AbstractAccount {
try {
remote_children = yield remote.list_child_folders_async(parent, cancellable);
} catch (Error err) {
// ignore everything but I/O errors
if (err is IOError)
// ignore everything but I/O and IMAP errors (cancellation is an IOError)
if (err is IOError || err is ImapError)
throw err;
}
......
......@@ -244,6 +244,10 @@ private class Geary.Imap.Account : BaseObject {
mailbox_info.mailbox);
}
// if no STATUS results are needed, bail out with what's been collected
if (cmd_map.size == 0)
return child_folders;
Gee.List<StatusData> status_results = new Gee.ArrayList<StatusData>();
Gee.Map<Command, StatusResponse> responses = yield send_multiple_async(cmd_map.keys,
null, status_results, cancellable);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment