Fix InternalCommand
Fix InternalTabComplete
Dieser Commit ist enthalten in:
Ursprung
bba1c1fbf7
Commit
a4d0f528f8
@ -39,8 +39,8 @@ class InternalCommand {
|
|||||||
|
|
||||||
boolean invoke(CommandSender commandSender, String[] args) {
|
boolean invoke(CommandSender commandSender, String[] args) {
|
||||||
if (args.length < parameters.length - 1) return false;
|
if (args.length < parameters.length - 1) return false;
|
||||||
Object[] objects = SWCommandUtils.generateArgumentArray(commandSender, parameters, args);
|
|
||||||
try {
|
try {
|
||||||
|
Object[] objects = SWCommandUtils.generateArgumentArray(commandSender, method, parameters, args);
|
||||||
method.setAccessible(true);
|
method.setAccessible(true);
|
||||||
method.invoke(swCommand, objects);
|
method.invoke(swCommand, objects);
|
||||||
} catch (IllegalArgumentException | IllegalAccessException e) {
|
} catch (IllegalArgumentException | IllegalAccessException e) {
|
||||||
|
@ -39,8 +39,8 @@ class InternalTabComplete {
|
|||||||
|
|
||||||
SWCommandUtils.TabComplete invoke(CommandSender commandSender, String[] args) {
|
SWCommandUtils.TabComplete invoke(CommandSender commandSender, String[] args) {
|
||||||
if (args.length < parameters.length - 1) return null;
|
if (args.length < parameters.length - 1) return null;
|
||||||
Object[] objects = SWCommandUtils.generateArgumentArray(commandSender, parameters, args);
|
|
||||||
try {
|
try {
|
||||||
|
Object[] objects = SWCommandUtils.generateArgumentArray(commandSender, method, parameters, args);
|
||||||
method.setAccessible(true);
|
method.setAccessible(true);
|
||||||
return (SWCommandUtils.TabComplete) method.invoke(swCommand, objects);
|
return (SWCommandUtils.TabComplete) method.invoke(swCommand, objects);
|
||||||
} catch (IllegalArgumentException | IllegalAccessException e) {
|
} catch (IllegalArgumentException | IllegalAccessException e) {
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren