Opened on 01/21/2015 at 07:47:34 AM
Closed on 01/22/2015 at 09:56:30 AM
#1841 closed change (fixed)
Get rid of the URI class in favor of URL objects
Reported by: | sebastian | Assignee: | sebastian |
---|---|---|---|
Priority: | P4 | Milestone: | Adblock-Plus-1.8.11-for-Chrome-Opera-Safari |
Module: | Platform | Keywords: | |
Cc: | Blocked By: | ||
Blocking: | #1801 | Platform: | Unknown |
Ready: | yes | Confidential: | no |
Tester: | Verified working: | ||
Review URL(s): |
Description
Background
Firefox provides the nsIURI class for parsing URLs. Currently we maintain our own implementation of nsIURI for Chrome and Safari. But recent versions of Chrome and Safari come with built-in URL objects. Using URL objects will be more efficient and reduces the amount of complexity, in particular when we are going to process all URLs (including special URLs) with #1801.
What to change
Remove the URI class and use built-in URL objects instead. Implement a polyfill for older browser versions that doesn't have URL objects or all of its properties we need. Such a polyfill can easily be implemented with the help of an <a> element, which can be used to parse URLs.
Hints for testers
This change will affect all kinds of filter matching, in particular key-based whitelisting.
Attachments (0)
Change History (2)
comment:1 Changed on 01/21/2015 at 07:54:54 AM by sebastian
- Review URL(s) modified (diff)
- Status changed from new to reviewing
comment:2 Changed on 01/22/2015 at 09:56:30 AM by sebastian
- Milestone set to Adblock-Plus-for-Chrome-Opera-Safari-next
- Resolution set to fixed
- Status changed from reviewing to closed
https://hg.adblockplus.org/adblockpluschrome/rev/e4a0c21f6c46