mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-30 23:29:54 +00:00
SimpleCommandMap: beware case mismatches in alias recursion, closes #3281
This commit is contained in:
parent
199fa61aef
commit
f1083bd9c4
@ -72,6 +72,7 @@ use function explode;
|
|||||||
use function implode;
|
use function implode;
|
||||||
use function min;
|
use function min;
|
||||||
use function preg_match_all;
|
use function preg_match_all;
|
||||||
|
use function strcasecmp;
|
||||||
use function stripslashes;
|
use function stripslashes;
|
||||||
use function strpos;
|
use function strpos;
|
||||||
use function strtolower;
|
use function strtolower;
|
||||||
@ -296,7 +297,7 @@ class SimpleCommandMap implements CommandMap{
|
|||||||
|
|
||||||
if($command === null){
|
if($command === null){
|
||||||
$bad[] = $commandString;
|
$bad[] = $commandString;
|
||||||
}elseif($commandName === $alias){
|
}elseif(strcasecmp($commandName, $alias) === 0){
|
||||||
$recursive[] = $commandString;
|
$recursive[] = $commandString;
|
||||||
}else{
|
}else{
|
||||||
$targets[] = $commandString;
|
$targets[] = $commandString;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user