3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-19 04:50:06 +01:00

Allow command line arg to allow normal reload

Dieser Commit ist enthalten in:
Aikar 2016-03-21 21:56:52 -04:00
Ursprung 646b62a220
Commit e091466f34

Datei anzeigen

@ -1,4 +1,4 @@
From 6b8f5a4b05511bf5b5b10776f02951b702c56fb9 Mon Sep 17 00:00:00 2001 From 208b1904b32400b1745e6c89be57fded2d285a60 Mon Sep 17 00:00:00 2001
From: William <admin@domnian.com> From: William <admin@domnian.com>
Date: Fri, 18 Mar 2016 03:28:07 -0400 Date: Fri, 18 Mar 2016 03:28:07 -0400
Subject: [PATCH] Add command to reload permissions.yml and require confirm to Subject: [PATCH] Add command to reload permissions.yml and require confirm to
@ -35,7 +35,7 @@ index 91bde81..6b1f2a4 100644
+ void reloadPermissions(); // Paper + void reloadPermissions(); // Paper
} }
diff --git a/src/main/java/org/bukkit/command/defaults/ReloadCommand.java b/src/main/java/org/bukkit/command/defaults/ReloadCommand.java diff --git a/src/main/java/org/bukkit/command/defaults/ReloadCommand.java b/src/main/java/org/bukkit/command/defaults/ReloadCommand.java
index c70d512..f48187a 100644 index c70d512..ee29ebb 100644
--- a/src/main/java/org/bukkit/command/defaults/ReloadCommand.java --- a/src/main/java/org/bukkit/command/defaults/ReloadCommand.java
+++ b/src/main/java/org/bukkit/command/defaults/ReloadCommand.java +++ b/src/main/java/org/bukkit/command/defaults/ReloadCommand.java
@@ -11,15 +11,33 @@ public class ReloadCommand extends BukkitCommand { @@ -11,15 +11,33 @@ public class ReloadCommand extends BukkitCommand {
@ -54,7 +54,7 @@ index c70d512..f48187a 100644
if (!testPermission(sender)) return true; if (!testPermission(sender)) return true;
+ // Paper start - Reload permissions.yml & require confirm + // Paper start - Reload permissions.yml & require confirm
+ boolean confirmed = false; + boolean confirmed = System.getProperty("LetMeReload") != null;
+ if (args.length == 1) { + if (args.length == 1) {
+ if (args[0].equalsIgnoreCase("permissions")) { + if (args[0].equalsIgnoreCase("permissions")) {
+ Bukkit.getServer().reloadPermissions(); + Bukkit.getServer().reloadPermissions();