From 409fd5b1706ecf78b685c0968bb538b396130102 Mon Sep 17 00:00:00 2001 From: Paldiu Date: Sun, 29 Jan 2023 01:05:35 -0600 Subject: [PATCH] Fix null error --- src/main/java/mc/unraveled/reforged/command/MuteCMD.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/mc/unraveled/reforged/command/MuteCMD.java b/src/main/java/mc/unraveled/reforged/command/MuteCMD.java index 4435927..27e25d4 100644 --- a/src/main/java/mc/unraveled/reforged/command/MuteCMD.java +++ b/src/main/java/mc/unraveled/reforged/command/MuteCMD.java @@ -39,7 +39,8 @@ public class MuteCMD extends AbstractCommandBase { if (duration == 0) return Component.text("Invalid duration."); MuteService service = new MuteService(getPlugin().getPIPELINE(), "MuteService", duration); - + service.setInfractionData(infData); + if (!infData.isMuted()) { infData.setMuted(true); getPlugin().getScheduler().queue(service).subscribe();