From 720e8ec8eeb69d24afbb6b14068563cde2d470f0 Mon Sep 17 00:00:00 2001 From: Keuin Date: Thu, 23 Apr 2020 14:51:29 +0800 Subject: Version 1.1.0-dev: - Optimized backup lag (using async I/O). - Added twice confirmation /kb confirm and cancellation /kb cancel, to avoid mistake. - Added countdown before restoring. - Adjusted some text. - Code optimization. --- .../java/com/keuin/kbackupfabric/util/PermissionValidator.java | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 src/main/java/com/keuin/kbackupfabric/util/PermissionValidator.java (limited to 'src/main/java/com/keuin/kbackupfabric/util/PermissionValidator.java') diff --git a/src/main/java/com/keuin/kbackupfabric/util/PermissionValidator.java b/src/main/java/com/keuin/kbackupfabric/util/PermissionValidator.java new file mode 100644 index 0000000..9d37901 --- /dev/null +++ b/src/main/java/com/keuin/kbackupfabric/util/PermissionValidator.java @@ -0,0 +1,9 @@ +package com.keuin.kbackupfabric.util; + +import net.minecraft.server.command.ServerCommandSource; + +public class PermissionValidator { + public static boolean op(ServerCommandSource commandSource) { + return commandSource.hasPermissionLevel(4); + } +} -- cgit v1.2.3