Merge branch 'kyozm/proper-lack-of-permission-messages' into 'master'

proper message on permission check failure  for commands

Closes #303

See merge request veloren/veloren!592
This commit is contained in:
Songtronix 2019-10-13 08:39:30 +00:00
commit 8d272c8234

View File

@ -61,8 +61,9 @@ impl ChatCommand {
if !server.entity_is_admin(entity) {
server.clients.notify(
entity,
ServerMsg::private(String::from(
"Unavailable command '/{}'.\nType '/help' for available commands",
ServerMsg::private(format!(
"You don't have permission to use '/{}'.",
self.keyword
)),
);
return;