mirror of
https://github.com/essentials/Essentials.git
synced 2025-08-22 22:34:43 +02:00
Revert "/me crashes ementalo's face for making the client crash."
This reverts commit 95a6008941
.
And fix the original bug.
This commit is contained in:
@@ -417,7 +417,9 @@ public class EssentialsPlayerListener implements Listener
|
||||
if (event.getView().getTopInventory().getType() == InventoryType.PLAYER)
|
||||
{
|
||||
final User user = ess.getUser(event.getWhoClicked());
|
||||
if (user.isInvSee() && !user.isAuthorized("essentials.invsee.modify"))
|
||||
final User invOwner = ess.getUser(event.getView().getPlayer());
|
||||
if (user.isInvSee() && (!user.isAuthorized("essentials.invsee.modify")
|
||||
|| invOwner.isAuthorized("essentials.invsee.preventmodify")))
|
||||
{
|
||||
event.setCancelled(true);
|
||||
}
|
||||
|
Reference in New Issue
Block a user