mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2024-11-23 07:20:50 +01:00
Update GuildManager.java
This commit is contained in:
parent
8e9cea8f83
commit
694a70cf20
@ -185,7 +185,7 @@ public class GuildManager {
|
||||
}
|
||||
|
||||
|
||||
public void joinGuild(Guild guild, GameClient client, int userId, boolean acceptRequest) {
|
||||
public boolean joinGuild(Guild guild, GameClient client, int userId, boolean acceptRequest) {
|
||||
boolean error = false;
|
||||
try (Connection connection = Emulator.getDatabase().getDataSource().getConnection()) {
|
||||
try (PreparedStatement statement = connection.prepareStatement("SELECT COUNT(id) as total FROM guilds_members WHERE user_id = ?")) {
|
||||
@ -282,6 +282,8 @@ public class GuildManager {
|
||||
} catch (SQLException e) {
|
||||
LOGGER.error("Caught SQL exception", e);
|
||||
}
|
||||
|
||||
return !error;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user