mirror of
https://github.com/axllent/mailpit.git
synced 2025-06-06 23:36:23 +02:00
Chore: Delete multiple POP3 messages in single action
This commit is contained in:
parent
710f093561
commit
70baf12adb
@ -93,10 +93,10 @@ func handleClient(conn net.Conn) {
|
|||||||
|
|
||||||
defer func() {
|
defer func() {
|
||||||
if state == UPDATE {
|
if state == UPDATE {
|
||||||
for _, id := range toDelete {
|
|
||||||
_ = storage.DeleteMessages([]string{id})
|
|
||||||
}
|
|
||||||
if len(toDelete) > 0 {
|
if len(toDelete) > 0 {
|
||||||
|
if err := storage.DeleteMessages(toDelete); err != nil {
|
||||||
|
logger.Log().Errorf("[pop3] error deleting: %s", err.Error())
|
||||||
|
}
|
||||||
// Update web UI to remove deleted messages
|
// Update web UI to remove deleted messages
|
||||||
websockets.Broadcast("prune", nil)
|
websockets.Broadcast("prune", nil)
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user