From a5c3de5c42d45637b778ef3920d98035d00f16d6 Mon Sep 17 00:00:00 2001 From: CyR1en Date: Sun, 5 Nov 2023 11:49:14 -0700 Subject: [PATCH] null check --- .../com/cyr1en/commandprompter/prompt/ContextProcessor.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/cyr1en/commandprompter/prompt/ContextProcessor.java b/src/main/java/com/cyr1en/commandprompter/prompt/ContextProcessor.java index 41c4fe2..a1a212e 100644 --- a/src/main/java/com/cyr1en/commandprompter/prompt/ContextProcessor.java +++ b/src/main/java/com/cyr1en/commandprompter/prompt/ContextProcessor.java @@ -45,7 +45,8 @@ protected void process(PromptContext context) { plugin.getMessenger().sendMessage(context.getSender(), plugin.getI18N().getFormattedProperty("PromptInProgress", plugin.getConfiguration().cancelKeyword())); - context.getCancellable().setCancelled(true); + if(context.getCancellable() != null) + context.getCancellable().setCancelled(true); return; }