mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2025-01-04 23:32:55 +08:00
refactor: null check is not necessary, we have instanceof
This commit is contained in:
parent
45bf5edb13
commit
809009f96c
@ -16,7 +16,7 @@ public class HandlerSceneEntityDrownReq extends PacketHandler {
|
||||
|
||||
GameEntity entity = session.getPlayer().getScene().getEntityById(req.getEntityId());
|
||||
|
||||
if (entity == null || !(entity instanceof EntityMonster || entity instanceof EntityAvatar)) {
|
||||
if (!(entity instanceof EntityMonster || entity instanceof EntityAvatar)) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user