Skip to content

Commit

Permalink
Add missing disabled region support check.
Browse files Browse the repository at this point in the history
Fixes WORLDGUARD-3839.
  • Loading branch information
wizjany committed Jun 21, 2017
1 parent 84bc322 commit 3a8e3e8
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -515,6 +515,7 @@ public void onDamageEntity(DamageEntityEvent event) {
@EventHandler(ignoreCancelled = true)
public void onVehicleExit(VehicleExitEvent event) {
Entity vehicle = event.getVehicle();
if (!isRegionSupportEnabled(vehicle.getWorld())) return; // Region support disabled
Entity exited = event.getExited();

if (vehicle instanceof Tameable && exited instanceof Player) {
Expand Down

0 comments on commit 3a8e3e8

Please sign in to comment.