diff options
Diffstat (limited to 'spark-velocity/src')
-rw-r--r-- | spark-velocity/src/main/java/me/lucko/spark/velocity/SparkVelocityPlugin.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/spark-velocity/src/main/java/me/lucko/spark/velocity/SparkVelocityPlugin.java b/spark-velocity/src/main/java/me/lucko/spark/velocity/SparkVelocityPlugin.java index fef48e7..749319d 100644 --- a/spark-velocity/src/main/java/me/lucko/spark/velocity/SparkVelocityPlugin.java +++ b/spark-velocity/src/main/java/me/lucko/spark/velocity/SparkVelocityPlugin.java @@ -103,8 +103,9 @@ public class SparkVelocityPlugin implements SparkPlugin<CommandSource>, Command } @Override - public Set<CommandSource> getSenders() { + public Set<CommandSource> getSendersWithPermission(String permission) { Set<CommandSource> senders = new HashSet<>(this.proxy.getAllPlayers()); + senders.removeIf(sender -> !sender.hasPermission(permission)); senders.add(this.proxy.getConsoleCommandSource()); return senders; } |