Closed
Bug 1319939
Opened 8 years ago
Closed 8 years ago
Remove String generics uses in toolkit/mozapps/extensions/content
Categories
(Toolkit :: Add-ons Manager, defect)
Toolkit
Add-ons Manager
Tracking
()
RESOLVED
FIXED
mozilla53
Tracking | Status | |
---|---|---|
firefox53 | --- | fixed |
People
(Reporter: anba, Assigned: anba)
References
Details
(Whiteboard: triaged)
Attachments
(1 file, 1 obsolete file)
(deleted),
patch
|
anba
:
review+
|
Details | Diff | Splinter Review |
The various String generic methods are non-standard APIs and we plan to warn when they're used (bug 1319926) and eventually want to remove them completely (bug 1222552). As a first step we need to replace all String generic uses in Firefox with the counterpart from String.prototype.
In toolkit/mozapps/extensions/content/blocklist.js and toolkit/mozapps/extensions/content/extensions.js, String.localeCompare needs to be replaced with a call to String.prototype.localeCompare.
Assignee | ||
Comment 1•8 years ago
|
||
Attachment #8814233 -
Flags: review?(rhelmer)
Comment 2•8 years ago
|
||
Comment on attachment 8814233 [details] [diff] [review]
bug1319939.patch
Review of attachment 8814233 [details] [diff] [review]:
-----------------------------------------------------------------
Thanks!
::: toolkit/mozapps/extensions/content/blocklist.js
@@ +27,5 @@
> bundle.GetStringFromName("restartLaterButton.accesskey"));
>
> var richlist = document.getElementById("addonList");
> var list = gArgs.list;
> + list.sort(function(a, b) { return String(a.name).localeCompare(b.name); });
nit: this could be an arrow function w/ concise body if you want
Attachment #8814233 -
Flags: review?(rhelmer) → review+
Updated•8 years ago
|
Whiteboard: triaged
Assignee | ||
Comment 3•8 years ago
|
||
Updated patch to replace the function expression with an arrow function per review comments. Carrying r+ from rhelmer.
Attachment #8814233 -
Attachment is obsolete: true
Attachment #8815481 -
Flags: review+
Assignee | ||
Comment 4•8 years ago
|
||
(In reply to Robert Helmer [:rhelmer] from comment #2)
> Thanks!
Thanks for reviewing!
Keywords: checkin-needed
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/5897fbfa16c9
Remove String generics uses in toolkit/mozapps/extensions/content. r=rhelmer
Keywords: checkin-needed
Comment 6•8 years ago
|
||
bugherder |
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla53
You need to log in
before you can comment on or make changes to this bug.
Description
•