Program: 172818
Project: 172818
Buggy source:
@Listener public void onBlockBreak(ChangeBlockEvent.Break event){
  if (event.getCause().root() instanceof Player) {
    Player player=(Player)event.getCause().root();
    if (!EagleFactions.AdminList.contains(player.getUniqueId())) {
      for (      Transaction<BlockSnapshot> transaction : event.getTransactions()) {
        World world=player.getWorld();
        if (MainLogic.getSafeZoneWorldNames().contains(world.getName())) {
          event.setCancelled(true);
          return;
        }
 else         if (MainLogic.getWarZoneWorldNames().contains(world.getName()) && MainLogic.isBlockDestroyingInWarZoneDisabled()) {
          event.setCancelled(true);
          return;
        }
        Vector3i claim=transaction.getFinal().getLocation().get().getChunkPosition();
        Optional<Faction> optionalPlayerFaction=FactionLogic.getFactionByPlayerUUID(player.getUniqueId());
        Optional<Faction> optionalChunkFaction=FactionLogic.getFactionByChunk(world.getUniqueId(),claim);
        if (optionalChunkFaction.isPresent()) {
          if (optionalChunkFaction.get().Name.equals("String_Node_Str") && player.hasPermission("String_Node_Str")) {
            return;
          }
 else           if (optionalChunkFaction.get().Name.equals("String_Node_Str") && player.hasPermission("String_Node_Str")) {
            return;
          }
 else           if (optionalPlayerFaction.isPresent()) {
            if (!FlagManager.canBreakBlock(player,optionalPlayerFaction.get(),optionalChunkFaction.get())) {
              player.sendMessage(Text.of(PluginInfo.ErrorPrefix,PluginMessages.YOU_DONT_HAVE_PRIVILEGES_TO_DESTROY_BLOCKS_HERE));
              event.setCancelled(true);
              return;
            }
          }
 else {
            event.setCancelled(true);
            player.sendMessage(Text.of(PluginInfo.ErrorPrefix,TextColors.RED,PluginMessages.THIS_LAND_BELONGS_TO_SOMEONE_ELSE));
            return;
          }
        }
      }
    }
  }
 else {
    for (    Transaction<BlockSnapshot> transaction : event.getTransactions()) {
      World world=transaction.getFinal().getLocation().get().getExtent();
      if (MainLogic.getSafeZoneWorldNames().contains(world.getName())) {
        event.setCancelled(true);
        return;
      }
 else       if (MainLogic.getWarZoneWorldNames().contains(world.getName()) && MainLogic.isBlockDestroyingInWarZoneDisabled()) {
        event.setCancelled(true);
        return;
      }
      Vector3i claim=transaction.getFinal().getLocation().get().getChunkPosition();
      Optional<Faction> optionalChunkFaction=FactionLogic.getFactionByChunk(world.getUniqueId(),claim);
      if (optionalChunkFaction.isPresent()) {
        if (!optionalChunkFaction.get().Name.equals("String_Node_Str") && !optionalChunkFaction.get().Name.equals("String_Node_Str") && MainLogic.isBlockDestroyingDisabled()) {
          event.setCancelled(true);
          return;
        }
 else         if (optionalChunkFaction.get().Name.equals("String_Node_Str")) {
          event.setCancelled(true);
          return;
        }
 else         if (optionalChunkFaction.get().Name.equals("String_Node_Str") && MainLogic.isBlockDestroyingInWarZoneDisabled()) {
          event.setCancelled(true);
          return;
        }
      }
    }
  }
}

Fixed version (ground truth):
@Listener public void onBlockBreak(ChangeBlockEvent.Break event){
  if (event.getCause().root() instanceof Player) {
    Player player=(Player)event.getCause().root();
    if (!EagleFactions.AdminList.contains(player.getUniqueId())) {
      for (      Transaction<BlockSnapshot> transaction : event.getTransactions()) {
        World world=player.getWorld();
        if (MainLogic.getSafeZoneWorldNames().contains(world.getName())) {
          event.setCancelled(true);
          return;
        }
 else         if (MainLogic.getWarZoneWorldNames().contains(world.getName()) && MainLogic.isBlockDestroyingInWarZoneDisabled()) {
          event.setCancelled(true);
          return;
        }
        Vector3i claim=transaction.getFinal().getLocation().get().getChunkPosition();
        Optional<Faction> optionalPlayerFaction=FactionLogic.getFactionByPlayerUUID(player.getUniqueId());
        Optional<Faction> optionalChunkFaction=FactionLogic.getFactionByChunk(world.getUniqueId(),claim);
        if (optionalChunkFaction.isPresent()) {
          if (optionalChunkFaction.get().Name.equals("String_Node_Str") && player.hasPermission("String_Node_Str")) {
            return;
          }
 else           if (optionalChunkFaction.get().Name.equals("String_Node_Str") && player.hasPermission("String_Node_Str")) {
            return;
          }
 else           if (optionalPlayerFaction.isPresent()) {
            if (!FlagManager.canBreakBlock(player,optionalPlayerFaction.get(),optionalChunkFaction.get())) {
              player.sendMessage(Text.of(PluginInfo.ErrorPrefix,TextColors.RED,PluginMessages.YOU_DONT_HAVE_PRIVILEGES_TO_DESTROY_BLOCKS_HERE));
              event.setCancelled(true);
              return;
            }
          }
 else {
            event.setCancelled(true);
            player.sendMessage(Text.of(PluginInfo.ErrorPrefix,TextColors.RED,PluginMessages.THIS_LAND_BELONGS_TO_SOMEONE_ELSE));
            return;
          }
        }
      }
    }
  }
 else {
    for (    Transaction<BlockSnapshot> transaction : event.getTransactions()) {
      World world=transaction.getFinal().getLocation().get().getExtent();
      if (MainLogic.getSafeZoneWorldNames().contains(world.getName())) {
        event.setCancelled(true);
        return;
      }
 else       if (MainLogic.getWarZoneWorldNames().contains(world.getName()) && MainLogic.isBlockDestroyingInWarZoneDisabled()) {
        event.setCancelled(true);
        return;
      }
      Vector3i claim=transaction.getFinal().getLocation().get().getChunkPosition();
      Optional<Faction> optionalChunkFaction=FactionLogic.getFactionByChunk(world.getUniqueId(),claim);
      if (optionalChunkFaction.isPresent()) {
        if (!optionalChunkFaction.get().Name.equals("String_Node_Str") && !optionalChunkFaction.get().Name.equals("String_Node_Str") && MainLogic.isBlockDestroyingDisabled()) {
          event.setCancelled(true);
          return;
        }
 else         if (optionalChunkFaction.get().Name.equals("String_Node_Str")) {
          event.setCancelled(true);
          return;
        }
 else         if (optionalChunkFaction.get().Name.equals("String_Node_Str") && MainLogic.isBlockDestroyingInWarZoneDisabled()) {
          event.setCancelled(true);
          return;
        }
      }
    }
  }
}