From 9efd5de8728923160355b128705f6b84c12a2296 Mon Sep 17 00:00:00 2001 From: Xavier Sellier Date: Mon, 7 May 2018 20:54:52 -0400 Subject: [PATCH] Add a check to the PurchaseTask.purchase method to prevent NullPointerException --- .../src/org/godotengine/godot/payments/PaymentsManager.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/android/java/src/org/godotengine/godot/payments/PaymentsManager.java b/platform/android/java/src/org/godotengine/godot/payments/PaymentsManager.java index bdfbee155ae..7240047821e 100644 --- a/platform/android/java/src/org/godotengine/godot/payments/PaymentsManager.java +++ b/platform/android/java/src/org/godotengine/godot/payments/PaymentsManager.java @@ -211,7 +211,7 @@ public class PaymentsManager { } public void requestPurchase(final String sku, String transactionId) { - if (!mSetupDone) return; + if (!isConnected()) return; PurchaseTask purchaseTask = new PurchaseTask(mService, Godot.getInstance()) { @Override