Replace Integer == with Integer.intValue() == so as to avoid edge case errors

This commit is contained in:
AlexTheCoder 2016-12-16 23:11:56 -05:00 committed by cnr
parent 1cb6151817
commit 941b33bcfc
4 changed files with 8 additions and 8 deletions

View File

@ -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();
}

View File

@ -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();
}

View File

@ -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();
}

View File

@ -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!");
}