title: After cancelling the purchase made by google play billing processing the purchase query shows purchase state as 1 in the loop
body: <p>I have purchased and cancelled the order. So it got refunded. After the refund the purchaseState is in 0 (UNSPECIFIED_STATE). Hereafter cancellation of the purchaseQuerySkus return the state as 0.</p>
  <p>But the for loop returns the value as 1 for getPurchaseState.</p>
  <p>But while processing it satisfying the condition. It is weird.</p>
  <pre><code>List returns for me [Purchase.Json: {
          &quot;orderId&quot;: &quot;orderID&quot;,
          &quot;packageName&quot;: &quot;com.android.app&quot;,
          &quot;productId&quot;: &quot;in_app&quot;,
          &quot;purchaseTime&quot;: 29323923232,
          &quot;purchaseState&quot;: 0,
          &quot;purchaseToken&quot;: &quot;weorehrhjewrhewirhewiruhewfbewfbweuyfbwehfbweyfbwefbwefweuyfhweyufhwe&quot;,
          &quot;quantity&quot;: 1,
          &quot;acknowledged&quot;: true
      }]
  </code></pre>
  <p>Code:</p>
  <pre><code>     private List&lt;Purchase&gt; purchaseQuerySkus;
      
      private void queryPurchasesAsync() {
              if(mBillingClient.isReady()) {
                  LogUtils.LOGI(TAG, &quot;queryPurchasesAsync&quot;);
                  billingClient.queryPurchasesAsync(BillingClient.SkuType.INAPP, new PurchasesResponseListener() {
                      @Override
                      public void onQueryPurchasesResponse(@NonNull BillingResult billingResult, @NonNull List&lt;Purchase&gt; list) {
                          LogUtils.LOGI(TAG, &quot;queryPurchasesAsync list&quot; + list);
                          purchaseQuerySkus = list;
                      }
                  });
              }
          }
      
      Checking the purchase is already made or not after the cancellation. It returning the purchaseState as 0. But the print values shows as 1.
      
       if (billingClient.isReady()) {
                      queryPurchasesAsync();
                      LogUtils.LOGI(TAG, &quot;QUE_PUR_LIST_SIZE &quot; + purchaseQuerySkus.size()); 
                      //It returns the size of the list as 1
         
                      for (Purchase pur : purchaseQuerySkus) {
                          String thisSku = pur.getSkus().get(0); //my sku value
                          LogUtils.LOGI(TAG, &quot;pur.getPurchase state &quot; + pur.getPurchaseState()); //It prints the value as 1 
  But the returned list has the purchaseState as 0 which I have added above.
                          // So it satisfying the condition and showing the item was purchased
                          if (pur.getPurchaseState() == Purchase.PurchaseState.PURCHASED) {
                         // Acknowledging the user if purchased
      
                       }
             
  
     
  
     
  </code></pre>