title: Chrome Extension - Request Optional Permissions for current tab
body: <p>I'm trying to require tab permission for current origin.
  Ex: I'm on <a href="http://stackoverflow.com">http://stackoverflow.com</a>, clicking on badge, then on button from popup, and I should get a prompt box to allow manipulating on this tab.</p>
  
  <p>What I'm doing: </p>
  
  <ul>
  <li>manifest <pre>
  ...
  "permissions": ["tabs", "contextMenus"],
  "optional_permissions": [ <code>"&lt;all_urls&gt;"</code> ],
  ...
  </pre></li>
  <li><p>popup <pre> $('#reqPermision').click(function()
  {
      bg.reqPerm(url);
  });</pre></p></li>
  <li><p>background <pre> function reqPerm(url)
  {
      chrome.permissions.request({permissions: ['tabs'], origins: [url]}, function (granted)
      {
          log('permision:', granted)
      });
  }</pre></p></li>
  </ul>
  
  <p>What I'm getting: </p>
  
  <blockquote>
    <p>Error during <strong>permissions.request</strong>: Optional permissions must be listed in extension manifest.</p>
  </blockquote>
  
  <p>If I set url manually <em>(in this ex. <a href="https://stackoverflow.com/">https://stackoverflow.com/</a>)</em> in "optional_permissions" array, all is working how I need.</p>