Open Bug 1571718 Opened 5 years ago Updated 2 years ago

browser.search.get should return a valid favIconUrl or wait for it to be ready before resolving

Categories

(WebExtensions :: General, defect, P3)

defect

Tracking

(Not tracked)

People

(Reporter: robwu, Unassigned)

Details

The browser.search.get API returns the icons of an installed search provider. When a search extension has just been installed, its icon has not necessarily finished loading (SearchEngine.jsm maps remote http(s) URLs to a data: URL before assigning it to engine.iconURI), and the favIconUrl is currently undefined instead of a URL.

The browser.search.get API should try to return a valid favIconUrl if an engine has one. There are several potential ways to do so, choose one that fits best:

  • Use the original http(s) URL if the response is not ready yet.
  • Use a dummy URL that resolves to the desired icon URL (e.g. maybe in conjunction with bug 1315616).
  • Wait with resolving the browser.search.get promise until all icons have loaded.
Priority: -- → P3
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.