Skip to content

Commit 63caac2

Browse files
committed
Update Player#performCommand javadoc and signature
1 parent 2a1871b commit 63caac2

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

paper-api/src/main/java/org/bukkit/entity/Player.java

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
import org.bukkit.block.TileState;
4444
import org.bukkit.block.data.BlockData;
4545
import org.bukkit.block.sign.Side;
46+
import org.bukkit.command.CommandException;
4647
import org.bukkit.conversations.Conversable;
4748
import org.bukkit.event.block.BlockBreakEvent;
4849
import org.bukkit.event.block.BlockDropItemEvent;
@@ -469,10 +470,12 @@ default void kick(final net.kyori.adventure.text.@Nullable Component message) {
469470
/**
470471
* Makes the player perform the given command
471472
*
472-
* @param command Command to perform
473-
* @return true if the command was successful, otherwise false
473+
* @param command the command to perform. Example: <code>test abc 123</code>
474+
* @return {@code true} if the command was successful, otherwise {@code false}
475+
* @throws CommandException thrown when the executor for the given command fails with an unhandled exception
476+
* @see Server#dispatchCommand(org.bukkit.command.CommandSender, String)
474477
*/
475-
public boolean performCommand(String command);
478+
boolean performCommand(String command) throws CommandException;
476479

477480
/**
478481
* Returns true if the entity is supported by a block.

0 commit comments

Comments
 (0)