Skip to content

Commit

Permalink
Undo oopsie regarding team chest locks
Browse files Browse the repository at this point in the history
  • Loading branch information
MrEAlderson committed Sep 4, 2024
1 parent f272f64 commit d6633d5
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
import de.marcely.bedwars.tools.location.XYZYP;
import me.metallicgoat.tweaksaddon.config.MainConfig;
import org.bukkit.Location;
import org.bukkit.Material;
import org.bukkit.block.Block;
import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler;
Expand All @@ -18,9 +17,7 @@ public class LockTeamChest implements Listener {
// Many people will want team chests disabled, use this with only regular chests
@EventHandler
public void playerOpenArenaChest(PlayerOpenArenaChestEvent event) {
final Block teamChestBlock = event.getChestBlock();

if (!MainConfig.lock_team_chest_enabled || teamChestBlock.getType() == Material.ENDER_CHEST)
if (!MainConfig.lock_team_chest_enabled || !event.isTeamChest())
return;

final Arena arena = event.getArena();
Expand Down

0 comments on commit d6633d5

Please sign in to comment.