nextcloud / nextcloud/mail

Outbox message won't be saved unless the send button is clicked

Open
#10,755 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

1. to develop bug feature: outbox feature:composer regression
Dominant language
JavaScript
Stars
1k
Forks
348
Avg merge
12h 28m
Merged PRs (30d)
91

Description

Steps to reproduce
  1. Have a message in the outbox.
  2. Click on it to edit it.
Case 1
  1. Wait some time for it to be saved
  2. Observe error message in bottom left corner of the composer: Error saving draft
Case 2
  1. Close the modal or click outside.
  2. Observe toast: Failed to save message
Case 3
  1. Wait some time until the draft was saved.
  2. Close the modal now.
  3. Observe toast: Message saved
  4. Open the same message again.
  5. Observe that changes have been lost.

Changes are lost in all three cases.

Expected behavior

My changes should always be saved regardless if I press send again. That should be the case for the debounced background save as well as when closing/minimizing the composer.

Actual behavior

My changes are never saved unless I click the send button manually.

Mail app version

4.1.2 (also main)

Additional info

Could be a regression from https://github.com/nextcloud/mail/pull/8469.

Requires https://github.com/nextcloud/mail/pull/10754 (in order to be able to actually edit messages)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing PR 8469 and the prerequisite PR 10754, then trace the outbox composer paths for debounced background saves and saves triggered when closing or minimizing. Reproduce the three cases from the issue and confirm that edited messages persist without clicking send, including after reopening the message.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.