Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/mail.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristoph Wurst <christoph@winzerhof-wurst.at>2022-04-06 21:05:45 +0300
committerChristoph Wurst <christoph@winzerhof-wurst.at>2022-04-07 10:20:00 +0300
commitc9d343725f159a897228e0396eb552a4bbceaf9e (patch)
treef4990afd5fcaaec2c1c49bbe3826fd5da443bf5d /src
parent49470b953023d26704de517ea48be1516773bb05 (diff)
Only delete drafts that exist
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Diffstat (limited to 'src')
-rw-r--r--src/components/NewMessageModal.vue8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/components/NewMessageModal.vue b/src/components/NewMessageModal.vue
index 0135e5d15..e9961ed62 100644
--- a/src/components/NewMessageModal.vue
+++ b/src/components/NewMessageModal.vue
@@ -124,9 +124,11 @@ export default {
await this.$store.dispatch('outbox/sendMessage', { id: message.id })
- // Remove old draft envelope
- this.$store.commit('removeEnvelope', { id: data.draftId })
- this.$store.commit('removeMessage', { id: data.draftId })
+ if (data.draftId) {
+ // Remove old draft envelope
+ this.$store.commit('removeEnvelope', { id: data.draftId })
+ this.$store.commit('removeMessage', { id: data.draftId })
+ }
}
},
recipientToRfc822(recipient) {