imap: use imap.Wait() to eliminate cmd.InProgress()