File/New/Saved Search produces exception, if no account/no folder is selected at folder pane (Error: folder is undefined Source File: chrome://messenger/content/folderPane.js Line: 1463)

VERIFIED FIXED in Thunderbird 12.0

Status

MailNews Core
Backend
VERIFIED FIXED
8 years ago
5 years ago

People

(Reporter: World, Assigned: aceman)

Tracking

Trunk
Thunderbird 12.0

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

8 years ago
> Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1b5pre) Gecko/20090426 Shredder/3.0b3pre

When no account/no folder was selected at folder pane,
  Changed from initial "All Folders" mode to other mode, Unread/Favorite/Recent,
  Or returned to "All Folders")
File/New/Saved Search produced following exception.
> Error: folder is undefined
> Source File: chrome://messenger/content/folderPane.js Line: 1463
> (This exception occurs upon each "File/New/Saved Search")
Avobe exception didn't occur if account or folder is selected at folder pane.

Error: folder is undefined Source File: chrome://messenger/content/folderPane.js Line: 1463
Wada is this a regression ?
Component: General → Mail Window Front End
QA Contact: general → front-end
(Reporter)

Updated

7 years ago
Component: Mail Window Front End → Backend
Product: Thunderbird → MailNews Core
QA Contact: front-end → backend
(Reporter)

Comment 2

7 years ago
> Wada is this a regression ?

Sorry but I don't know. I happened to see the problem, and the problem was reproduced by very simple operation I stated in comment #0.
(Assignee)

Comment 3

6 years ago
This is still happening in TB12.

What should happen in this case? Just catch the exception and do nothing? Or show some prompt?
(Assignee)

Comment 4

6 years ago
I can do the clean exiting from the function. But if we want any UI stuff...
What about a status bar message? Is there something already available? There must be other cases where we want to tell "No folder selected" so I could reuse that?

Comment 5

6 years ago
I'd suggest if no folder is selected, fall back to the default account root, and show the dialog.
(Assignee)

Comment 6

6 years ago
Good idea. Patch coming.
Assignee: nobody → acelists
Status: NEW → ASSIGNED
OS: Windows XP → All
Hardware: x86 → All
(Assignee)

Comment 7

6 years ago
Created attachment 583921 [details] [diff] [review]
fix
Attachment #583921 - Flags: ui-review?(bwinton)
Comment on attachment 583921 [details] [diff] [review]
fix

Since the UI isn't really changing, I don't think you need a ui-review from me.

So I'll give it a regular review instead.  ;)

The code looks pretty good.  The change is small and simple.  r=me.

Thanks,
Blake.
Attachment #583921 - Flags: ui-review?(bwinton) → review+
(Assignee)

Comment 9

6 years ago
Thanks.
Keywords: checkin-needed
(Assignee)

Comment 10

6 years ago
Well, very similar problem happens when using Folders->Favorite, when there are none to show, the left tree pane is empty. Restarting TB comes up with the msgAccountCentral.js pane showing about every action available, because it does not know which account is selected (none is). Clicking most of the commands throws an exception like
Error: window.parent.MsgJunkMail is not a function
Source File: chrome://messenger/content/msgAccountCentral.js
Line: 292

Is this filed somewhere?
(Assignee)

Comment 11

6 years ago
Actually, that one bug is expected, that Junk feature is not ready, but was unintentionally exposed in the situation I described.
The real errors are
"Error: GetSelectedMsgFolder() is null"

Off to bug 713277.
Keywords: checkin-needed
Target Milestone: --- → Thunderbird 12.0
Checked in: http://hg.mozilla.org/comm-central/rev/e657c5051b99
Status: ASSIGNED → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
(Assignee)

Updated

5 years ago
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.