summaryrefslogtreecommitdiffstats
path: root/netwerk/test/mochitests/file_chromecommon.js
blob: f31dabb76de30afd68386925280947f14f8c67a6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/* eslint-env mozilla/frame-script */

"use strict";

let cs = Cc["@mozilla.org/cookiemanager;1"].getService(Ci.nsICookieManager);

addMessageListener("getCookieCountAndClear", () => {
  let count = cs.cookies.length;
  cs.removeAll();

  sendAsyncMessage("getCookieCountAndClear:return", { count });
});

cs.removeAll();