Closed Bug 1052566 Opened 10 years ago Closed 10 years ago

Opening 'File' menu without account configured throws exception: Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIMsgAccountManager.defaultAccount] mail3PaneWindowCommands.js :: IsSendUnsentMsgsEnabled

Categories

(Thunderbird :: Mail Window Front End, defect)

defect
Not set
normal

Tracking

(thunderbird36 fixed)

RESOLVED FIXED
Thunderbird 36.0
Tracking Status
thunderbird36 --- fixed

People

(Reporter: aryx, Assigned: aryx)

Details

Attachments

(1 file, 1 obsolete file)

Thunderbird 34.0a1 20140723 on Windows 8.1

Opening the 'File' menu if no account has been configured throws an exception:

An error occurred updating the cmd_sendUnsentMsgs command: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIMsgAccountManager.defaultAccount]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: chrome://messenger/content/mail3PaneWindowCommands.js :: IsSendUnsentMsgsEnabled :: line 1149"  data: no] globalOverlay.js:83
Attached patch patch, v1 (obsolete) — Splinter Review
Attachment #8471707 - Flags: review?(mkmelin+mozilla)
Comment on attachment 8471707 [details] [diff] [review]
patch, v1

Review of attachment 8471707 [details] [diff] [review]:
-----------------------------------------------------------------

Ah, how wonderful :/ And we don't really even care about the identity...r=mkmelin

::: mail/base/content/mail3PaneWindowCommands.js
@@ +1127,5 @@
>                .getService(Components.interfaces.nsIMsgSendLater);
>  
> +  // If no account has been configured, there are no messages for sending.
> +  if (MailServices.accounts.accounts.length == 0)
> +    return false;

You could move this up first in this function.
Attachment #8471707 - Flags: review?(mkmelin+mozilla) → review+
https://hg.mozilla.org/comm-central/rev/fa22c20f0437
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 36.0
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: