Replace Integer == with Integer.intValue() == so as to avoid edge case errors
This commit is contained in:
parent
1cb6151817
commit
941b33bcfc
@ -137,7 +137,7 @@ public class CommunityJoinRequestsPage extends CommunitiesGUIPage
|
||||
@EventHandler
|
||||
public void onMembershipUpdate(CommunityMembershipUpdateEvent event)
|
||||
{
|
||||
if (event.getCommunity().getId() != _community.getId())
|
||||
if (event.getCommunity().getId().intValue() != _community.getId().intValue())
|
||||
{
|
||||
return;
|
||||
}
|
||||
@ -155,7 +155,7 @@ public class CommunityJoinRequestsPage extends CommunitiesGUIPage
|
||||
@EventHandler
|
||||
public void onRequestsUpdate(CommunityJoinRequestsUpdateEvent event)
|
||||
{
|
||||
if (event.getCommunity().getId() != _community.getId())
|
||||
if (event.getCommunity().getId().intValue() != _community.getId().intValue())
|
||||
{
|
||||
return;
|
||||
}
|
||||
@ -165,7 +165,7 @@ public class CommunityJoinRequestsPage extends CommunitiesGUIPage
|
||||
@EventHandler
|
||||
public void onCommunityDisband(CommunityDisbandEvent event)
|
||||
{
|
||||
if (_community.getId() == event.getCommunity().getId())
|
||||
if (_community.getId().intValue() == event.getCommunity().getId().intValue())
|
||||
{
|
||||
Viewer.closeInventory();
|
||||
}
|
||||
|
@ -145,7 +145,7 @@ public class CommunityMembersPage extends CommunitiesGUIPage
|
||||
@EventHandler
|
||||
public void onMembershipUpdate(CommunityMembershipUpdateEvent event)
|
||||
{
|
||||
if (event.getCommunity().getId() != _community.getId())
|
||||
if (event.getCommunity().getId().intValue() != _community.getId().intValue())
|
||||
{
|
||||
return;
|
||||
}
|
||||
@ -156,7 +156,7 @@ public class CommunityMembersPage extends CommunitiesGUIPage
|
||||
@EventHandler
|
||||
public void onCommunityDisband(CommunityDisbandEvent event)
|
||||
{
|
||||
if (_community.getId() == event.getCommunity().getId())
|
||||
if (_community.getId().intValue() == event.getCommunity().getId().intValue())
|
||||
{
|
||||
Viewer.closeInventory();
|
||||
}
|
||||
|
@ -107,7 +107,7 @@ public class CommunitySettingsPage extends CommunitiesGUIPage
|
||||
@EventHandler
|
||||
public void onMembershipUpdate(CommunityMembershipUpdateEvent event)
|
||||
{
|
||||
if (event.getCommunity().getId() != _community.getId())
|
||||
if (event.getCommunity().getId().intValue() != _community.getId().intValue())
|
||||
{
|
||||
return;
|
||||
}
|
||||
@ -131,7 +131,7 @@ public class CommunitySettingsPage extends CommunitiesGUIPage
|
||||
@EventHandler
|
||||
public void onCommunityDisband(CommunityDisbandEvent event)
|
||||
{
|
||||
if (_community.getId() == event.getCommunity().getId())
|
||||
if (_community.getId().intValue() == event.getCommunity().getId().intValue())
|
||||
{
|
||||
Viewer.closeInventory();
|
||||
}
|
||||
|
@ -669,7 +669,7 @@ public class GameHostManager implements Listener
|
||||
{
|
||||
if (isCommunityServer())
|
||||
{
|
||||
if (getOwner().getId() == event.getCommunity().getId())
|
||||
if (getOwner().getId().intValue() == event.getCommunity().getId().intValue())
|
||||
{
|
||||
setHostExpired(true, getOwner().getName() + " has disbanded and abandoned the server. Thanks for playing!");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user