Sat, 03 Jan 2015 20:18:00 +0100
Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.
1 /* Any copyright is dedicated to the Public Domain.
2 * http://creativecommons.org/publicdomain/zero/1.0/ */
4 function testSameVersion() {
5 let mozSettings = window.navigator.mozSettings;
6 let forceSent = false;
8 mozSettings.addObserver("gecko.updateStatus", function statusObserver(setting) {
9 if (!forceSent) {
10 return;
11 }
13 mozSettings.removeObserver("gecko.updateStatus", statusObserver);
14 is(setting.settingValue, "already-latest-version");
15 cleanUp();
16 });
18 sendContentEvent("force-update-check");
19 forceSent = true;
20 }
22 // Update lifecycle callbacks
23 function preUpdate() {
24 testSameVersion();
25 }