mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 07:20:24 +01:00
Fix up NPE's in EntityMinecart/CraftVehicle and removed a little un-needed code in EntityArrow
By: speakeasy <mekevin1917@gmail.com>
This commit is contained in:
parent
52cc6f5bf6
commit
10b548b654
1 changed files with 1 additions and 1 deletions
|
@ -16,7 +16,7 @@ public abstract class CraftVehicle extends CraftEntity implements Vehicle {
|
|||
}
|
||||
|
||||
public Entity getPassenger() {
|
||||
return (getHandle().j.getBukkitEntity());
|
||||
return isEmpty()?null:(getHandle().j.getBukkitEntity());
|
||||
}
|
||||
|
||||
public boolean setPassenger(Entity passenger) {
|
||||
|
|
Loading…
Reference in a new issue