mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2025-01-18 23:46:28 +01:00
Prevent group join button reappearing after guild update
This commit is contained in:
parent
b9e573ae34
commit
57bb88bc17
@ -5095,12 +5095,15 @@ public class Room implements Comparable<Room>, ISerialize, Runnable
|
|||||||
{
|
{
|
||||||
if(guild.getRoomId() == this.id)
|
if(guild.getRoomId() == this.id)
|
||||||
{
|
{
|
||||||
THashMap<Integer, GuildMember> admins = Emulator.getGameEnvironment().getGuildManager().getOnlyAdmins(guild);
|
THashSet<GuildMember> members = Emulator.getGameEnvironment().getGuildManager().getGuildMembers(guild.getId());
|
||||||
|
|
||||||
for (Habbo habbo : this.getHabbos())
|
for (Habbo habbo : this.getHabbos())
|
||||||
{
|
{
|
||||||
GuildMember member = admins.get(habbo.getHabboInfo().getId());
|
Optional<GuildMember> member = members.stream().filter(m -> m.getUserId() == habbo.getHabboInfo().getId()).findAny();
|
||||||
habbo.getClient().sendResponse(new GuildInfoComposer(guild, habbo.getClient(), false, member));
|
|
||||||
|
if (!member.isPresent()) continue;
|
||||||
|
|
||||||
|
habbo.getClient().sendResponse(new GuildInfoComposer(guild, habbo.getClient(), false, member.get()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user