mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 19:49:44 +00:00
fix npe11(send message to yourself) & nc168
This commit is contained in:
parent
104244365b
commit
efca0f8398
1 changed files with 5 additions and 0 deletions
|
|
@ -72,8 +72,13 @@ class ChatAPI{
|
|||
$target = strtolower($n);
|
||||
if($target === "server" or $target === "console" or $target === "rcon"){
|
||||
$target = "Console";
|
||||
}else{
|
||||
return "The player is offline.";
|
||||
}
|
||||
}
|
||||
if(strtolower($target) === strtolower($issuer)){
|
||||
return "You can't send message to yourself.";
|
||||
}
|
||||
$mes = implode(" ", $params);
|
||||
$output .= "You're whispering to " . $target . ": " . $mes . "\n";
|
||||
if($target !== "Console" and $target !== "Rcon"){
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue