From 26cd14cdab684f9a1cb17c9eafd2c48aee2ba1eb Mon Sep 17 00:00:00 2001 From: Jeffrey Bunn Date: Wed, 22 Jan 2025 08:17:22 -0800 Subject: [PATCH] Fixed possible Nullpointexception when checking subscription status in Java --- code_blocks/customers/customer-info_12.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code_blocks/customers/customer-info_12.java b/code_blocks/customers/customer-info_12.java index 8e438f6a6..d3f530670 100644 --- a/code_blocks/customers/customer-info_12.java +++ b/code_blocks/customers/customer-info_12.java @@ -1,3 +1,4 @@ -if (customerInfo.getEntitlements().get().isActive()) { +if (customerInfo.getEntitlements().get() != null + && customerInfo.getEntitlements().get().isActive()) { // user has access to "your_entitlement_id" } \ No newline at end of file