Closed
Bug 1171408
Opened 10 years ago
Closed 10 years ago
Move NetworkEventsHandler.getString into WebConsoleClient
Categories
(DevTools :: Console, defect)
DevTools
Console
Tracking
(firefox41 fixed)
RESOLVED
FIXED
Firefox 41
Tracking | Status | |
---|---|---|
firefox41 | --- | fixed |
People
(Reporter: Honza, Assigned: Honza)
Details
Attachments
(1 file, 1 obsolete file)
4.58 KB,
patch
|
Honza
:
review+
|
Details | Diff | Splinter Review |
NetworkEventsHandler.getString() is a helper that should be sharable by other modules, so let's move it into WebConsoleClient object.
Honza
Assignee | ||
Comment 1•10 years ago
|
||
Assignee: nobody → odvarko
Status: NEW → ASSIGNED
Assignee | ||
Updated•10 years ago
|
Attachment #8615268 -
Flags: review?(past)
Comment 2•10 years ago
|
||
Comment on attachment 8615268 [details] [diff] [review]
bug1171408-1.patch
Review of attachment 8615268 [details] [diff] [review]:
-----------------------------------------------------------------
r=me with comments addressed.
::: toolkit/devtools/webconsole/client.js
@@ +8,5 @@
>
> const {Cc, Ci, Cu} = require("chrome");
> const DevToolsUtils = require("devtools/toolkit/DevToolsUtils");
> const EventEmitter = require("devtools/toolkit/event-emitter");
> +const promise = Cu.import("resource://gre/modules/Promise.jsm", {}).Promise;
We are trying to convert all imports to require() and the devtools loader already provides a require("promise") that can be used here.
@@ +627,5 @@
> + * @return object Promise
> + * A promise that is resolved when the full string contents
> + * are available, or rejected if something goes wrong.
> + */
> + getString: function(aStringGrip) {
Since this is a new method and the file is already inconsistent, let's avoid using the deprecated "aFoo" style for arguments and use the simpler "foo".
@@ +644,5 @@
> + let longStringClient = this.longString(aStringGrip);
> +
> + longStringClient.substring(initial.length, length, aResponse => {
> + if (aResponse.error) {
> + Cu.reportError(aResponse.error + ": " + aResponse.message);
Since this is now in toolkit, better use DevToolsUtils.reportException(), like we do elsewhere in this file, so that other embeddings can work properly.
Attachment #8615268 -
Flags: review?(past) → review+
Assignee | ||
Comment 3•10 years ago
|
||
All comments fixed.
Thanks for the review Panos!
Honza
Attachment #8615268 -
Attachment is obsolete: true
Attachment #8623681 -
Flags: review+
Assignee | ||
Updated•10 years ago
|
Attachment #8623681 -
Flags: review+ → review?(past)
Assignee | ||
Updated•10 years ago
|
Attachment #8623681 -
Flags: review?(past) → review+
Assignee | ||
Updated•10 years ago
|
Keywords: checkin-needed
Assignee | ||
Comment 4•10 years ago
|
||
Comment 5•10 years ago
|
||
In the future, please make sure your patch includes proper commit information when requesting checkin.
Keywords: checkin-needed
Assignee | ||
Comment 7•10 years ago
|
||
(In reply to Ryan VanderMeulen [:RyanVM UTC-4] from comment #5)
> In the future, please make sure your patch includes proper commit
> information when requesting checkin.
Oops, forgot to remove try info.
Thanks for fixing!
Honza
Comment 8•10 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
status-firefox41:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 41
Updated•7 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•