Program: 86068
Project: 86068
Buggy source:
@EventHandler public void onSignUse(PlayerInteractEvent event){
  if (event.hasBlock()) {
    if (event.getClickedBlock().getType() == Material.SIGN_POST || event.getClickedBlock().getType() == Material.WALL_SIGN) {
      if (event.getAction() != Action.RIGHT_CLICK_BLOCK) {
        return;
      }
      final Sign s=(Sign)event.getClickedBlock().getState();
      Arena arena=Util.getArenaBySignLocation(plugin,event.getClickedBlock().getLocation());
      if (arena != null) {
        Player p=event.getPlayer();
        if (!arena.containsPlayer(p.getName())) {
          arena.joinPlayerLobby(p.getName());
        }
 else {
          Util.sendMessage(plugin,p,pli.getMessagesConfig().you_already_are_in_arena.replaceAll("String_Node_Str",arena.getName()));
        }
      }
 else {
        Location l=Util.getComponentForArenaRaw(plugin,"String_Node_Str","String_Node_Str");
        if (l != null) {
          if (l.getWorld() != null) {
            if (l.distance(s.getLocation()) < 1) {
              for (              Arena a : pli.getArenas()) {
                if (a.getArenaState() == ArenaState.JOIN || a.getArenaState() == ArenaState.STARTING) {
                  if (!a.containsPlayer(event.getPlayer().getName())) {
                    a.joinPlayerLobby(event.getPlayer().getName());
                    break;
                  }
                }
              }
            }
          }
        }
      }
    }
 else     if (event.getClickedBlock().getType() == Material.CHEST) {
      Player p=event.getPlayer();
      if (pli.global_players.containsKey(p.getName())) {
        Arena a=pli.global_players.get(p.getName());
        if (a.getArenaState() == ArenaState.INGAME) {
          a.getSmartReset().addChanged(event.getClickedBlock(),event.getClickedBlock().getType().equals(Material.CHEST));
        }
      }
    }
 else     if (event.getClickedBlock().getType() == Material.TNT) {
      Player p=event.getPlayer();
      if (pli.global_players.containsKey(p.getName())) {
        Arena a=pli.global_players.get(p.getName());
        if (a.getArenaState() == ArenaState.INGAME) {
          a.getSmartReset().addChanged(event.getClickedBlock(),false);
        }
      }
    }
 else     if (event.getPlayer().getItemInHand().getType() == Material.WATER_BUCKET || event.getPlayer().getItemInHand().getType() == Material.WATER || event.getPlayer().getItemInHand().getType() == Material.LAVA_BUCKET || event.getPlayer().getItemInHand().getType() == Material.LAVA) {
      Player p=event.getPlayer();
      if (pli.global_players.containsKey(p.getName())) {
        Arena a=pli.global_players.get(p.getName());
        if (a.getArenaState() == ArenaState.INGAME) {
          a.getSmartReset().addChanged(event.getClickedBlock(),event.getClickedBlock().getType().equals(Material.CHEST));
        }
      }
    }
  }
  if (pli.global_lost.containsKey(event.getPlayer().getName()) || pli.getSpectatorManager().isSpectating(event.getPlayer())) {
    event.setCancelled(true);
  }
  if (event.hasItem()) {
    final Player p=event.getPlayer();
    if (!pli.global_players.containsKey(p.getName())) {
      return;
    }
    if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      pli.getClassesHandler().openGUI(p.getName());
      event.setCancelled(true);
    }
 else     if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      if (pli.global_players.get(p.getName()).getArenaState() != ArenaState.INGAME) {
        pli.global_players.get(p.getName()).leavePlayer(p.getName(),false,false);
        event.setCancelled(true);
      }
 else {
        if (pli.global_lost.containsKey(p.getName())) {
          pli.global_players.get(p.getName()).leavePlayer(p.getName(),false,false);
          event.setCancelled(true);
        }
      }
    }
 else     if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      if (pli.global_lost.containsKey(p.getName())) {
        pli.getSpectatorManager().openSpectatorGUI(p,pli.global_players.get(p.getName()));
        event.setCancelled(true);
      }
    }
 else     if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      if (pli.isAchievementGuiEnabled()) {
        pli.getArenaAchievements().openGUI(p.getName(),false);
        event.setCancelled(true);
      }
    }
 else     if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      if (plugin.getConfig().getBoolean("String_Node_Str")) {
        Bukkit.dispatchCommand(Bukkit.getConsoleSender(),plugin.getConfig().getString("String_Node_Str"));
      }
    }
  }
}

Fixed version (ground truth):
@EventHandler public void onSignUse(PlayerInteractEvent event){
  if (event.hasBlock()) {
    if (event.getClickedBlock().getType() == Material.SIGN_POST || event.getClickedBlock().getType() == Material.WALL_SIGN) {
      if (event.getAction() != Action.RIGHT_CLICK_BLOCK) {
        return;
      }
      final Sign s=(Sign)event.getClickedBlock().getState();
      Arena arena=Util.getArenaBySignLocation(plugin,event.getClickedBlock().getLocation());
      if (arena != null) {
        Player p=event.getPlayer();
        if (!arena.containsPlayer(p.getName())) {
          arena.joinPlayerLobby(p.getName());
        }
 else {
          Util.sendMessage(plugin,p,pli.getMessagesConfig().you_already_are_in_arena.replaceAll("String_Node_Str",arena.getName()));
        }
      }
 else {
        Location l=Util.getComponentForArenaRaw(plugin,"String_Node_Str","String_Node_Str");
        if (l != null) {
          if (l.getWorld() != null) {
            if (l.distance(s.getLocation()) < 1) {
              for (              Arena a : pli.getArenas()) {
                if (a.getArenaState() == ArenaState.JOIN || a.getArenaState() == ArenaState.STARTING) {
                  if (!a.containsPlayer(event.getPlayer().getName())) {
                    a.joinPlayerLobby(event.getPlayer().getName());
                    break;
                  }
                }
              }
            }
          }
        }
      }
    }
 else     if (event.getClickedBlock().getType() == Material.CHEST) {
      Player p=event.getPlayer();
      if (pli.global_players.containsKey(p.getName())) {
        Arena a=pli.global_players.get(p.getName());
        if (a.getArenaState() == ArenaState.INGAME) {
          a.getSmartReset().addChanged(event.getClickedBlock(),event.getClickedBlock().getType().equals(Material.CHEST));
        }
      }
    }
 else     if (event.getClickedBlock().getType() == Material.TNT) {
      Player p=event.getPlayer();
      if (pli.global_players.containsKey(p.getName())) {
        Arena a=pli.global_players.get(p.getName());
        if (a.getArenaState() == ArenaState.INGAME) {
          a.getSmartReset().addChanged(event.getClickedBlock(),false);
        }
      }
    }
 else     if (event.getPlayer().getItemInHand().getType() == Material.WATER_BUCKET || event.getPlayer().getItemInHand().getType() == Material.WATER || event.getPlayer().getItemInHand().getType() == Material.LAVA_BUCKET || event.getPlayer().getItemInHand().getType() == Material.LAVA) {
      Player p=event.getPlayer();
      if (pli.global_players.containsKey(p.getName())) {
        Arena a=pli.global_players.get(p.getName());
        if (a.getArenaState() == ArenaState.INGAME) {
          a.getSmartReset().addChanged(event.getClickedBlock(),event.getClickedBlock().getType().equals(Material.CHEST));
        }
      }
    }
  }
  if (pli.global_lost.containsKey(event.getPlayer().getName()) || pli.getSpectatorManager().isSpectating(event.getPlayer())) {
    event.setCancelled(true);
  }
  if (event.hasItem()) {
    final Player p=event.getPlayer();
    if (!pli.global_players.containsKey(p.getName())) {
      return;
    }
    if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      pli.getClassesHandler().openGUI(p.getName());
      event.setCancelled(true);
    }
 else     if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      if (pli.global_players.get(p.getName()).getArenaState() != ArenaState.INGAME) {
        pli.global_players.get(p.getName()).leavePlayer(p.getName(),false,false);
        event.setCancelled(true);
      }
 else {
        if (pli.global_lost.containsKey(p.getName())) {
          pli.global_players.get(p.getName()).leavePlayer(p.getName(),false,false);
          event.setCancelled(true);
        }
      }
    }
 else     if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      if (pli.global_lost.containsKey(p.getName())) {
        pli.getSpectatorManager().openSpectatorGUI(p,pli.global_players.get(p.getName()));
        event.setCancelled(true);
      }
    }
 else     if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      if (pli.isAchievementGuiEnabled()) {
        pli.getArenaAchievements().openGUI(p.getName(),false);
        event.setCancelled(true);
      }
    }
 else     if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      pli.getShopHandler().openGUI(p.getName());
      event.setCancelled(true);
    }
 else     if (event.getItem().getTypeId() == plugin.getConfig().getInt("String_Node_Str")) {
      if (plugin.getConfig().getBoolean("String_Node_Str")) {
        Bukkit.dispatchCommand(Bukkit.getConsoleSender(),plugin.getConfig().getString("String_Node_Str"));
      }
    }
  }
}