Checking the existence of a folder before performing an operation is not doing anything useful. When a folder doesn't exist, we want the operation to fail.
Here's partial protocol logs without the changes applied (before) and with the changes applied (after):
connX: IMAP connection number X
>>>: commands sent to the server
<<<: responses received from the server
Checking the existence of a folder before performing an operation is not doing anything useful. When a folder doesn't exist, we want the operation to fail.
Here's partial protocol logs without the changes applied (before) and with the changes applied (after):
connX
: IMAP connection number X>>>
: commands sent to the server<<<
: responses received from the serverEmpty trash
Before
After
Expunge command
Before
After
Expunge message
Before
After
Mark all as read
Before
After
Copy message
Before
After
Set flag
Before
After
There's still lots of potential to get rid of unnecessary commands (and even connections). But this PR is solely about the folder existence checks.