title: "Error: Parameter 1 required" when attempting to set a listener on onBeforeRequest
body: <p>background.js :</p>
  
  <pre><code>chrome.extension.onRequest.addListener(
      function(request, sender, sendResponse)
      {
          console.log(request.filter)
          chrome.webRequest.onBeforeRequest.addListener(request.func, request.filter, ["blocking"]);
      }
  );
  </code></pre>
  
  <p>content script:</p>
  
  <pre><code>chrome.extension.sendRequest(
      {
          func: requestInterceptor,
          filter: requestFilter
      }
  );
  </code></pre>
  
  <p>The line <code>chrome.webRequest.onBeforeRequest.addListener(request.func, request.filter, ["blocking"]);</code> is triggering the following error:</p>
  
  <pre><code>Error in event handler for 'undefined': Error: Parameter 1 is required.
  </code></pre>
  
  <p>How can I fix it?</p>