Program: 33921
Project: 33921
Buggy source:
@EventHandler(priority=EventPriority.LOWEST,ignoreCancelled=true) public void onVillagerSpawn(final CreatureSpawnEvent e){
  if (DEBUG2) {
    plugin.getLogger().info("String_Node_Str" + e.getEventName());
    plugin.getLogger().info(e.getSpawnReason().toString());
    plugin.getLogger().info(e.getEntityType().toString());
  }
  if (!(e.getEntity() instanceof Villager)) {
    return;
  }
  if (!e.getEntity().getWorld().equals(ASkyBlock.getIslandWorld())) {
    return;
  }
  if (Settings.villagerLimit <= 0) {
    return;
  }
  if (e.getSpawnReason() != SpawnReason.SPAWNER && e.getSpawnReason() != SpawnReason.BREEDING && e.getSpawnReason() != SpawnReason.DISPENSE_EGG && e.getSpawnReason() != SpawnReason.SPAWNER_EGG && e.getSpawnReason() != SpawnReason.CURED) {
    return;
  }
  Island island=plugin.getGrid().getProtectedIslandAt(e.getLocation());
  if (island == null || island.getOwner() == null || island.isSpawn()) {
    return;
  }
  int limit=Settings.villagerLimit * Math.max(1,plugin.getPlayers().getMembers(island.getOwner()).size());
  int pop=island.getPopulation();
  if (pop >= limit) {
    plugin.getLogger().warning("String_Node_Str" + island.getCenter().getBlockX() + "String_Node_Str"+ island.getCenter().getBlockZ()+ "String_Node_Str"+ limit);
    List<Entity> players=e.getEntity().getNearbyEntities(10,10,10);
    for (    Entity player : players) {
      if (player instanceof Player) {
        Player p=(Player)player;
        p.sendMessage(ChatColor.RED + plugin.myLocale(island.getOwner()).villagerLimitError.replace("String_Node_Str",String.valueOf(Settings.villagerLimit)));
      }
    }
    plugin.getMessages().tellTeam(island.getOwner(),ChatColor.RED + plugin.myLocale(island.getOwner()).villagerLimitError.replace("String_Node_Str",String.valueOf(Settings.villagerLimit)));
    if (e.getSpawnReason().equals(SpawnReason.CURED)) {
      ItemStack goldenApple=new ItemStack(Material.GOLDEN_APPLE);
      goldenApple.setDurability((short)1);
      e.getLocation().getWorld().dropItemNaturally(e.getLocation(),goldenApple);
    }
    e.setCancelled(true);
  }
}

Fixed version (ground truth):
@EventHandler(priority=EventPriority.LOWEST,ignoreCancelled=true) public void onVillagerSpawn(final CreatureSpawnEvent e){
  if (DEBUG2) {
    plugin.getLogger().info("String_Node_Str" + e.getEventName());
    plugin.getLogger().info(e.getSpawnReason().toString());
    plugin.getLogger().info(e.getEntityType().toString());
  }
  if (!(e.getEntity() instanceof Villager)) {
    return;
  }
  if (!e.getEntity().getWorld().equals(ASkyBlock.getIslandWorld())) {
    return;
  }
  if (Settings.villagerLimit <= 0) {
    return;
  }
  if (e.getSpawnReason() != SpawnReason.SPAWNER && e.getSpawnReason() != SpawnReason.BREEDING && e.getSpawnReason() != SpawnReason.DISPENSE_EGG && e.getSpawnReason() != SpawnReason.SPAWNER_EGG && e.getSpawnReason() != SpawnReason.CURED) {
    return;
  }
  Island island=plugin.getGrid().getProtectedIslandAt(e.getLocation());
  if (island == null || island.getOwner() == null || island.isSpawn()) {
    return;
  }
  int limit=Settings.villagerLimit * Math.max(1,plugin.getPlayers().getMembers(island.getOwner()).size());
  int pop=island.getPopulation();
  if (pop >= limit) {
    plugin.getLogger().warning("String_Node_Str" + island.getCenter().getBlockX() + "String_Node_Str"+ island.getCenter().getBlockZ()+ "String_Node_Str"+ limit);
    List<Entity> players=e.getEntity().getNearbyEntities(10,10,10);
    for (    Entity player : players) {
      if (player instanceof Player) {
        Player p=(Player)player;
        p.sendMessage(ChatColor.RED + plugin.myLocale(island.getOwner()).villagerLimitError.replace("String_Node_Str",String.valueOf(limit)));
      }
    }
    plugin.getMessages().tellTeam(island.getOwner(),ChatColor.RED + plugin.myLocale(island.getOwner()).villagerLimitError.replace("String_Node_Str",String.valueOf(limit)));
    if (e.getSpawnReason().equals(SpawnReason.CURED)) {
      ItemStack goldenApple=new ItemStack(Material.GOLDEN_APPLE);
      goldenApple.setDurability((short)1);
      e.getLocation().getWorld().dropItemNaturally(e.getLocation(),goldenApple);
    }
    e.setCancelled(true);
  }
}