Skip to content

Commit

Permalink
Implement proper Config getters in ChangeOwnerListener class.
Browse files Browse the repository at this point in the history
  • Loading branch information
BONNe committed Jan 2, 2019
1 parent a805c85 commit 6261309
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public ChangeOwnerListener(BiomesAddon addon)
public void onTeamSetOwnerEvent(TeamSetownerEvent event)
{
// Do nothing if biome reset is diabled.
if (!this.addon.getConfig().getBoolean("resetbiomes", false))
if (!this.addon.getSettings().isResetBiomes())
{
return;
}
Expand All @@ -48,6 +48,8 @@ public void onTeamSetOwnerEvent(TeamSetownerEvent event)

String defaultBiome;

// TODO: The same issue as with BiomesAddon class. It gets values but better would be to add them as
// dependencies.
if (skyBlock.isPresent() &&
skyBlock.get().getConfig().getString("world.world-name").
equalsIgnoreCase(Util.getWorld(event.getIsland().getWorld()).getName()))
Expand Down

0 comments on commit 6261309

Please sign in to comment.