title: BitcoinJ walletTemplate P2WPKH Send payment not working
body: <p>I have tried to use WalletTemplate sub-project inside <a href="https://github.com/bitcoinj/bitcoinj" rel="nofollow noreferrer">bitcoinJ</a> lib. I have tried p2pkh sends and they work fine. But then I tried to make P2WPKH payment but it failed with the following error message</p>
  
  <pre><code> org.bitcoinj.core.RejectedTransactionException: Reject: tx
   539c7f25b14b20dfad1ad66923fa59bf7531cd1ebda967e8346793fa2464f5dc for
   reason 'non-mandatory-script-verify-flag (Signature must be zero for
   failed CHECK(MULTI)SIG operation)' (64)
  </code></pre>
  
  <p>This behavior doesn't exist before <a href="https://github.com/bitcoinj/bitcoinj/commit/bc46e8518d677088b5b5a3a8dbdefa9958461c90" rel="nofollow noreferrer">commit</a>. So I'm not sure how to handle the changes introduced since this change.
  I have also create github <a href="https://github.com/bitcoinj/bitcoinj/issues/2006" rel="nofollow noreferrer">issue</a> to get more information but I haven't got any response yet. I have tried code outside of bitcoinj's walletTemplate in another project as follows: </p>
  
  <pre><code>    NetworkParameters params = TestNet3Params.get();
      Address destination = Address.fromString(params, strDest);
      Coin value = Coin.parseCoin(strValue);
      SendRequest request = SendRequest.to(destination, value);
  
      SendResult result = wallet.sendCoins(request);
  </code></pre>
  
  <p>Any help would be appreciated. Thanks</p>