mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-03 00:25:04 +00:00
Merge pull request #1383 from pmmp/quoted-command-args
Quoted command args & allow playernames with spaces
This commit is contained in:
@ -223,7 +223,7 @@ class SimpleCommandMap implements CommandMap{
|
|||||||
}
|
}
|
||||||
|
|
||||||
public function dispatch(CommandSender $sender, string $commandLine) : bool{
|
public function dispatch(CommandSender $sender, string $commandLine) : bool{
|
||||||
$args = explode(" ", $commandLine);
|
$args = array_map("stripslashes", str_getcsv($commandLine, " "));
|
||||||
$sentCommandLabel = "";
|
$sentCommandLabel = "";
|
||||||
$target = $this->matchCommand($sentCommandLabel, $args);
|
$target = $this->matchCommand($sentCommandLabel, $args);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user