diff --git a/src/main/java/com/eu/habbo/habbohotel/items/interactions/InteractionVoteCounter.java b/src/main/java/com/eu/habbo/habbohotel/items/interactions/InteractionVoteCounter.java index 54ea473b..b323fa52 100644 --- a/src/main/java/com/eu/habbo/habbohotel/items/interactions/InteractionVoteCounter.java +++ b/src/main/java/com/eu/habbo/habbohotel/items/interactions/InteractionVoteCounter.java @@ -18,7 +18,7 @@ public class InteractionVoteCounter extends HabboItem { private boolean frozen; private int votes; - private List votedUsers; + private final List votedUsers; public InteractionVoteCounter(ResultSet set, Item baseItem) throws SQLException { super(set, baseItem); @@ -69,7 +69,7 @@ public class InteractionVoteCounter extends HabboItem { @Override public void onClick(GameClient client, Room room, Object[] objects) throws Exception { - if (!((client != null && room != null && room.hasRights(client.getHabbo())) || (objects.length >= 2 && objects[1] instanceof WiredEffectType))) + if (room == null || !((client != null && room.hasRights(client.getHabbo())) || (objects.length >= 2 && objects[1] instanceof WiredEffectType))) return; this.frozen = !this.frozen;