mirror of
https://github.com/barkeser2002/Tenet.git
synced 2026-09-25 12:45:59 +03:00
28 lines
1.1 KiB
Diff
28 lines
1.1 KiB
Diff
--- ../src-base/minecraft/org/bukkit/command/SimpleCommandMap.java
|
|
+++ ../src-work/minecraft/org/bukkit/command/SimpleCommandMap.java
|
|
@@ -167,7 +167,7 @@
|
|
if (args.length == 0) {
|
|
return false;
|
|
}
|
|
-
|
|
+
|
|
String sentCommandLabel = args[0].toLowerCase();
|
|
Command target = getCommand(sentCommandLabel);
|
|
|
|
@@ -176,11 +176,15 @@
|
|
}
|
|
|
|
try {
|
|
+ target.timings.startTiming(); // Spigot
|
|
// Note: we don't return the result of target.execute as thats success / failure, we return handled (true) or not handled (false)
|
|
target.execute(sender, sentCommandLabel, Arrays_copyOfRange(args, 1, args.length));
|
|
+ target.timings.stopTiming(); // Spigot
|
|
} catch (CommandException ex) {
|
|
+ target.timings.stopTiming(); // Spigot
|
|
throw ex;
|
|
} catch (Throwable ex) {
|
|
+ target.timings.stopTiming(); // Spigot
|
|
throw new CommandException("Unhandled exception executing '" + commandLine + "' in " + target, ex);
|
|
}
|
|
|