Make SearchService more robust to Region.jsm failures
Categories
(Firefox :: Search, enhancement, P3)
Tracking
()
People
(Reporter: daleharvey, Unassigned)
Details
In https://bugzilla.mozilla.org/show_bug.cgi?id=1672164 the SearchService failed to load because a patched Region.jsm had a syntax error, while it was not a problem in our code it may be an idea to make the SearchService a little less fragile in case of problems like these
Updated•5 years ago
|
Comment 1•2 years ago
|
||
Looking at the current search service, all we directly depend on in Region is the Region.home getter this is a simple getter to return the attribute.
We also have a fallback in the search service should that value be undefined/empty.
Additionally we recently made Firefox work better if the search service failed to work (although that does mean that search isn't available).
I think that given that we have linting and automated tests, if Region.sys.mjs has a syntax error then something has failed in the process for shipping.
In this case, it was a Linux distribution that had modified the code, and there probably isn't too much we can do about that, except recommend that they at least run the linters when doing patches.
Description
•