Make simplified SchemeIs methods on nsIURI (SchemeIsHTTP, SchemeIsHTTPS, etc...)

RESOLVED FIXED in Firefox 66

Status

()

enhancement
P4
normal
RESOLVED FIXED
5 months ago
5 months ago

People

(Reporter: qdot, Assigned: qdot)

Tracking

unspecified
mozilla66
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox66 fixed)

Details

(Whiteboard: [necko-triaged])

Attachments

(1 attachment)

Ballparking from looking at searchfox (https://searchfox.org/mozilla-central/search?q=SchemeIs&path=), something like 80% of our SchemeIs calls are for http, https, chrome, about, and a few other types. We can just tack methods onto nsIURI for these specific cases to clean up code, versus having to pass protocol strings everywhere.

Whiteboard: [necko-triaged]
Create conveinence functions for common protocols used in SchemeIs
queries.

:valentin I just copied over the SchemeIs functions from bug 1518956. I can reduce the amount of protocols supported by these convenience functions if you think this list is still overkill.

Attachment #9035716 - Attachment description: Bug 1518964 - Add SchemeIs conveinence functions; → Bug 1518964 - Add SchemeIs convenience functions;

Comment 3

5 months ago
Pushed by kmachulis@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/d288304b11fa
Add SchemeIs convenience functions; r=valentin

Comment 4

5 months ago
bugherder
Status: NEW → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla66
You need to log in before you can comment on or make changes to this bug.