Fix sidebar count updates when closing mailbox. (closes #3938)
The context unread and flagged counts were being updated too early in
mx_close_mailbox(). Cancelling at any of the following prompts would
leave them in an incorrect state. Additionally, $move could increase
the delete count (for flagged messages), and $delete, if answered no,
could turn off message deletion.
Move all the sidebar buffy stat updating to the bottom of the
function, after all the prompts and processing.