From 4631dcf8577db081ede4312282b800f56665a575 Mon Sep 17 00:00:00 2001 From: Luck Date: Mon, 10 Apr 2017 20:57:59 +0100 Subject: [PATCH] Ensure expired permissions are removed when users/groups are loaded for commands --- .../luckperms/common/commands/impl/group/GroupMainCommand.java | 2 ++ .../luckperms/common/commands/impl/user/UserMainCommand.java | 1 + 2 files changed, 3 insertions(+) diff --git a/common/src/main/java/me/lucko/luckperms/common/commands/impl/group/GroupMainCommand.java b/common/src/main/java/me/lucko/luckperms/common/commands/impl/group/GroupMainCommand.java index e2403abc..5556c857 100644 --- a/common/src/main/java/me/lucko/luckperms/common/commands/impl/group/GroupMainCommand.java +++ b/common/src/main/java/me/lucko/luckperms/common/commands/impl/group/GroupMainCommand.java @@ -67,8 +67,10 @@ public class GroupMainCommand extends MainCommand { if (group == null) { Message.GROUP_NOT_FOUND.send(sender); + return null; } + group.auditTemporaryPermissions(); return group; } diff --git a/common/src/main/java/me/lucko/luckperms/common/commands/impl/user/UserMainCommand.java b/common/src/main/java/me/lucko/luckperms/common/commands/impl/user/UserMainCommand.java index 045d074b..7c1ca50d 100644 --- a/common/src/main/java/me/lucko/luckperms/common/commands/impl/user/UserMainCommand.java +++ b/common/src/main/java/me/lucko/luckperms/common/commands/impl/user/UserMainCommand.java @@ -91,6 +91,7 @@ public class UserMainCommand extends MainCommand { return null; } + user.auditTemporaryPermissions(); return user; }