From 40ca3a388dfc3d85e594b272d9447e76cb651b99 Mon Sep 17 00:00:00 2001 From: Dom Bridge Date: Thu, 12 Jan 2023 08:18:59 +0000 Subject: [PATCH] Fix build --- src/main/java/com/eu/habbo/database/DatabaseConstants.java | 7 +++++++ .../incoming/navigator/ForwardToSomeRoomEvent.java | 3 ++- .../outgoing/modtool/ModeratorUserInfoComposer.java | 2 +- 3 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 src/main/java/com/eu/habbo/database/DatabaseConstants.java diff --git a/src/main/java/com/eu/habbo/database/DatabaseConstants.java b/src/main/java/com/eu/habbo/database/DatabaseConstants.java new file mode 100644 index 00000000..c6d5e811 --- /dev/null +++ b/src/main/java/com/eu/habbo/database/DatabaseConstants.java @@ -0,0 +1,7 @@ +package com.eu.habbo.database; + +public class DatabaseConstants { + public static final String CAUGHT_SQL_EXCEPTION = "Caught SQL exception"; + + public final static String USER_ID = DatabaseConstants.USER_ID; +} diff --git a/src/main/java/com/eu/habbo/messages/incoming/navigator/ForwardToSomeRoomEvent.java b/src/main/java/com/eu/habbo/messages/incoming/navigator/ForwardToSomeRoomEvent.java index 4b0b6c3d..abb96fdb 100644 --- a/src/main/java/com/eu/habbo/messages/incoming/navigator/ForwardToSomeRoomEvent.java +++ b/src/main/java/com/eu/habbo/messages/incoming/navigator/ForwardToSomeRoomEvent.java @@ -8,6 +8,7 @@ import com.eu.habbo.messages.outgoing.users.NavigatorSettingsComposer; import java.util.ArrayList; import java.util.Collections; +import java.util.List; public class ForwardToSomeRoomEvent extends MessageHandler { @Override @@ -15,7 +16,7 @@ public class ForwardToSomeRoomEvent extends MessageHandler { String data = this.packet.readString(); if (data.equals("random_friending_room")) { - ArrayList rooms = Emulator.getGameEnvironment().getRoomManager().getActiveRooms(); + List rooms = Emulator.getGameEnvironment().getRoomManager().getActiveRooms(); if (!rooms.isEmpty()) { Collections.shuffle(rooms); this.client.sendResponse(new RoomForwardMessageComposer(rooms.get(0).getId())); diff --git a/src/main/java/com/eu/habbo/messages/outgoing/modtool/ModeratorUserInfoComposer.java b/src/main/java/com/eu/habbo/messages/outgoing/modtool/ModeratorUserInfoComposer.java index 43430920..e8400694 100644 --- a/src/main/java/com/eu/habbo/messages/outgoing/modtool/ModeratorUserInfoComposer.java +++ b/src/main/java/com/eu/habbo/messages/outgoing/modtool/ModeratorUserInfoComposer.java @@ -32,7 +32,7 @@ public class ModeratorUserInfoComposer extends MessageComposer { try { int totalBans = 0; - totalBans = getTotalBansFromDB(totalBans); + totalBans = getTotalBansFromDB(); this.response.appendInt(this.set.getInt(DatabaseConstants.USER_ID)); this.response.appendString(this.set.getString("username"));