Closed Bug 317396 Opened 19 years ago Closed 19 years ago

templates disappear when saving

Categories

(Thunderbird :: General, defect)

x86
All
defect
Not set
major

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: bugzilla2, Assigned: Bienvenu)

References

Details

(Keywords: dataloss, fixed1.8, regression)

Attachments

(2 files)

User-Agent:       Opera/9.0 (Windows NT 5.1; U; de)
Build Identifier: Version 1.5 (20051025)

when you write a  new mail that is based on an template, and safe it during writing, the template disapeares from the template folder...

btw, on every safe, tb creates a new mail in the drafts folder. this also happens with the automatic safe process of tb 1.5...

Reproducible: Always

Steps to Reproduce:
1. open a template
2. write some text
3. press  CTRL+S


Actual Results:  
the template is gone :-(

Expected Results:  
a draft should have been saved in the drafts folder, without deleting the template

Richard Neal has postet this before (Bugzilla Bug 273277, Mesage 3). He did that as a folowup on an generic tb-template-improve-request, so I wrote it here as a standalone message...
Severity: major → normal
Summary: templates disapear when saving → templates disappear when saving
->NEW using Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8) Gecko/20051120 Thunderbird/1.5 ID:2005112006.

I can see this regression at least going back to end of june... This could be pretty visible due to auto-save.
Severity: normal → major
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: regression
OS: Windows XP → All
This is almost a dupe of/related/fallout from bug 292568, or could-be-dupe of suite bug 308037. See bug 292568 comment 14.

I don't know if "edit as new" in the Templates folder *is* the same thing as double-clicking and starting to edit it, but it should behave the same way shouldn't it?  
Keywords: dataloss
Attached patch proposed fixSplinter Review
Original message should never be deleted if the original message was a template. This fixes it for me.
Attachment #204276 - Flags: review?(bienvenu)
Requesting blocking 1.8.0.1, but I really think this ought to be fixed for 1.5 final.
Flags: blocking1.8.0.1?
Magnus, with your fix, does saving the new message multiple times delete the previous drafts?
Comment on attachment 204276 [details] [diff] [review]
proposed fix

with this change, saved drafts of templates don't get deleted...granted, that's better than deleting templates on send, but we should be able to get both to work.
Attachment #204276 - Flags: review?(bienvenu) → review-
(In reply to comment #5)
> Magnus, with your fix, does saving the new message multiple times delete the
> previous drafts?

No. But that does not seem to work without it either. I don't think I'll be able to come up with a better fix, at least not anyway.

> with this change, saved drafts of templates don't get deleted...granted,
> that's better than deleting templates on send, but we should be able to get
> both to work.

On *save* and auto-save, not on send, that's this bug (or was that a typo?). I'm not really sure I see the problem with my patch..?
I meant, not anytime soon...
Attached patch proposed fixSplinter Review
Can you try this patch? It contains your change, plus a change to make it so saving/auto-saving/sending will delete the previous draft, if any, but not the template. Thx!
Assignee: mscott → bienvenu
Status: NEW → ASSIGNED
Attachment #204496 - Flags: superreview?(mscott)
(In reply to comment #9)
> Created an attachment (id=204496) [edit]
> proposed fix
> 
> Can you try this patch? It contains your change, plus a change to make it so
> saving/auto-saving/sending will delete the previous draft, if any, but not the
> template. Thx!

Yep, that patch works fine for me, seems to fix those problems. Nice work!

Attachment #204496 - Flags: superreview?(mscott) → superreview+
fix checked in, thx for the fix, Magnus!
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
we're going to put this in 1.5
Keywords: fixed1.8
Will this fix be included in Thunderbird 1.5 RC2?
(In reply to comment #13)
> Will this fix be included in Thunderbird 1.5 RC2?

Yes, the fix has been checked in to the branch and trunk.
whatever the next rc is (coming out tomorrow, I believe), yes.
Problem is fixed in 1.5 RC 2..

Thank you all for your effort
this is a bug fix taken for thunderbird on the 1.8 branch after firefox 1.5 was released but before the 1.5.0.x tag was cut from 1.8. Therefore I believe this fix is already in the 1.5.0.x branch. Clearing the flag.
Flags: blocking1.8.0.1?
Blocks: 288702
You need to log in before you can comment on or make changes to this bug.