Created
June 19, 2015 21:01
-
-
Save wbamberg/0ed8cfa6d3bc4fc2235f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let {WebRequest} = Cu.import("resource://gre/modules/WebRequest.jsm", {}); | |
function listen() { | |
WebRequest.onSendHeaders.addListener(listener, {}, ["requestHeaders"]); | |
} | |
function listener(e) { | |
console.log("onSendHeaders"); | |
console.log(e); | |
} | |
function unlisten() { | |
WebRequest.onSendHeaders.removeListener(listener); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi
I try use this code in FireFox 42.0a2, but in console error i got have a this error:
it is bug? or API has changed?