2019-06-08 17:41:56 +00:00
|
|
|
package imap
|
|
|
|
|
|
|
|
import (
|
2021-11-05 09:19:46 +00:00
|
|
|
"git.sr.ht/~rjarry/aerc/worker/types"
|
2019-06-08 17:41:56 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
func (imapw *IMAPWorker) handleCreateDirectory(msg *types.CreateDirectory) {
|
|
|
|
if err := imapw.client.Create(msg.Directory); err != nil {
|
2019-07-11 04:49:09 +00:00
|
|
|
if msg.Quiet {
|
2019-06-08 17:41:56 +00:00
|
|
|
return
|
|
|
|
}
|
|
|
|
imapw.worker.PostMessage(&types.Error{
|
|
|
|
Message: types.RespondTo(msg),
|
|
|
|
Error: err,
|
|
|
|
}, nil)
|
|
|
|
} else {
|
|
|
|
imapw.worker.PostMessage(&types.Done{types.RespondTo(msg)}, nil)
|
|
|
|
}
|
|
|
|
}
|