mirror of
https://github.com/essentials/Essentials.git
synced 2025-08-22 06:12:56 +02:00
Block explicit /home bed, unless user has "essentials.home.bed" permission.
This does not effect the '/home' command when used with no arguments. In this case, a player will still be sent to the bed home, if they have no Ess home set.
This commit is contained in:
@@ -44,7 +44,7 @@ public class Commandhome extends EssentialsCommand
|
|||||||
}
|
}
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if ("bed".equalsIgnoreCase(homeName))
|
if ("bed".equalsIgnoreCase(homeName) && user.isAuthorized("essentials.home.bed"))
|
||||||
{
|
{
|
||||||
final Location bed = player.getBedSpawnLocation();
|
final Location bed = player.getBedSpawnLocation();
|
||||||
if (bed != null && bed.getBlock().getType() == Material.BED_BLOCK)
|
if (bed != null && bed.getBlock().getType() == Material.BED_BLOCK)
|
||||||
|
Reference in New Issue
Block a user