title: MetaMask - RPC Error: Permissions request already pending, in Angular 10
body: <p>I have integrated the MetaMask with Angular and while opening up the MetaMask extension from the code I am getting this error.</p>
  <p>Following is my code for opening up the extension.
  I am calling this function on a click to open MetaMask where its giving that error</p>
  <p><strong>MetaMask - RPC Error: Permissions request already pending; please wait. {code: -32002, message: &quot;Permissions request already pending; please wait.&quot;}</strong></p>
  <pre><code>ethEnabled(template?): any
    {
      if ((window as any).web3)
      {
        (window as any).web3 = new Web3((window as any).web3.currentProvider);
        (window as any).ethereum.enable();
        console.log((window as any).ethereum.enable());
  
      }
      else
      {
        this.modalRef = this.modalService.show(template);
      }
    }
  
  </code></pre>