Invalid :command error message contains "Error:" twice

RESOLVED FIXED in Firefox 63

Status

defect
P3
normal
RESOLVED FIXED
Last year
11 months ago

People

(Reporter: fvsch, Assigned: nchevobbe)

Tracking

Trunk
Firefox 63

Firefox Tracking Flags

(firefox63 fixed)

Details

Attachments

(1 attachment)

Steps to reproduce:

1. Open the Console
2. Type `:hey` and Enter
3. Message printed: "Error: Error: 'hey' is not a valid command"

In #3, the expected message would be: "Error: 'hey' is not a valid command"
Assignee: nobody → nchevobbe
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Priority: -- → P3
When the command is invalid, we throw an error with
the appropriate message. But in the caller, we then
wrap this error in a string, which resulted in a
message in the console which looked like "Error: Error:".
Picking only error.message when wrapping the error
fixes this issue.
Comment on attachment 8999090 [details]
Bug 1480823 - Fix invalid command error message; r=yulia.

Yulia Startsev [:yulia] has approved the revision.
Attachment #8999090 - Flags: review+
Pushed by nchevobbe@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/0287730fa808
Fix invalid command error message; r=yulia.
https://hg.mozilla.org/mozilla-central/rev/0287730fa808
Status: ASSIGNED → RESOLVED
Closed: 11 months ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 63
You need to log in before you can comment on or make changes to this bug.