title: chrome.declarativeContent.onPageChanged.removeRules(undefined, function(){}) not working
body: <p>When I try to remove all rules with chrome.declarativeContent.onPageChanged.removeRules(), it says: </p>
  
  <blockquote>
    <p>Error in response to events.removeRules: Error: Invalid value for
    argument 1. Property '.1': Value does not match any valid type
    choices, Property '.2': Value does not match any valid type choices.</p>
  </blockquote>
  
  <p>This is the code, I just copied it from here: <a href="https://developer.chrome.com/extensions/examples/api/pageAction/pageaction_by_url/background.js" rel="nofollow">https://developer.chrome.com/extensions/examples/api/pageAction/pageaction_by_url/background.js</a></p>
  
  <pre><code>// When the extension is installed or upgraded ...
  chrome.runtime.onInstalled.addListener(function () {
      console.log('installed');
      // Replace all rules ...
      chrome.declarativeContent.onPageChanged.removeRules(undefined, function () {
          console.log('removed');
          // With a new rule ...
          chrome.declarativeContent.onPageChanged.addRules([
              {
                  conditions: [
                      new chrome.declarativeContent.PageStateMatcher({
                          pageUrl: {
                              urlEquals: 'www.google.com'
                          }
                      })
                  ],
  
                  actions: [new chrome.declarativeContent.ShowPageAction(), console.log('hi'), init()]
              }
          ]);
      });
  });
  </code></pre>
  
  <p>The weird thing is that the console says (in this order):</p>
  
  <blockquote>
    <p>hi <br>
    installed <br>
    removed <br>
    <strong>error above (error in response to...)</strong></p>
  </blockquote>
  
  <p>Any help would be appreciated. Thanks.</p>