Program: 137682
Project: 137682
Buggy source:
@Override public String getText(Object element){
  try {
    if (element != null && element instanceof IRepositoryNode) {
      IRepositoryNode node=(IRepositoryNode)element;
      if (node instanceof RecycleBinRepNode || node instanceof ExchangeCategoryRepNode || node instanceof ExchangeComponentRepNode) {
        return node.getLabel();
      }
 else       if (node instanceof DBConnectionSubFolderRepNode) {
        return ((DBConnectionSubFolderRepNode)node).getObject().getLabel();
      }
 else       if (node instanceof DBConnectionFolderRepNode) {
        return DefaultMessagesImpl.getString("String_Node_Str");
      }
 else       if (node instanceof DFConnectionSubFolderRepNode) {
        return ((DFConnectionSubFolderRepNode)node).getObject().getLabel();
      }
 else       if (node instanceof DFConnectionFolderRepNode) {
        return DefaultMessagesImpl.getString("String_Node_Str");
      }
 else       if (node instanceof MDMSchemaRepNode) {
        return ((MDMSchemaRepNode)node).getLabel();
      }
 else       if (node instanceof MDMConnectionSubFolderRepNode) {
        return ((MDMConnectionSubFolderRepNode)node).getObject().getLabel();
      }
 else       if (node instanceof MDMConnectionFolderRepNode) {
        return DefaultMessagesImpl.getString("String_Node_Str");
      }
 else       if (node instanceof DBTableFolderRepNode) {
        return ((DBTableFolderRepNode)node).getLabel();
      }
 else       if (node instanceof DBViewFolderRepNode) {
        return ((DBViewFolderRepNode)node).getLabel();
      }
 else       if (node instanceof DBColumnFolderRepNode) {
        return ((DBColumnFolderRepNode)node).getNodeName();
      }
 else       if (node instanceof DFColumnFolderRepNode) {
        return ((DFColumnFolderRepNode)node).getNodeName();
      }
 else       if (node instanceof DBTableRepNode) {
        return ((DBTableRepNode)node).getLabel();
      }
 else       if (node instanceof DBViewRepNode) {
        return ((DBViewRepNode)node).getLabel();
      }
 else       if (node instanceof DBColumnRepNode) {
        DBColumnRepNode columnNode=(DBColumnRepNode)node;
        return columnNode.getLabel() + LEFT + columnNode.getNodeDataType()+ RIGHT;
      }
 else       if (node instanceof DFColumnRepNode) {
        DFColumnRepNode dfColumnRepNode=(DFColumnRepNode)node;
        String nodeDataType=dfColumnRepNode.getNodeDataType();
        return dfColumnRepNode.getId() + LEFT + nodeDataType+ RIGHT;
      }
 else       if (node instanceof MDMXmlElementRepNode) {
        MDMXmlElementRepNode mdmColumnRepNode=(MDMXmlElementRepNode)node;
        String nodeDataType=mdmColumnRepNode.getNodeDataType();
        if (!PluginConstant.EMPTY_STRING.equals(nodeDataType)) {
          return mdmColumnRepNode.getTdXmlElementType().getName() + LEFT + nodeDataType+ RIGHT;
        }
        return mdmColumnRepNode.getTdXmlElementType().getName();
      }
 else       if (node instanceof AnalysisRepNode || node instanceof ReportRepNode || node instanceof SysIndicatorDefinitionRepNode|| node instanceof PatternRepNode|| node instanceof RuleRepNode|| node instanceof SourceFileRepNode|| node instanceof DFConnectionRepNode|| node instanceof MDMConnectionRepNode) {
        return node.getLabel() + "String_Node_Str" + node.getObject().getVersion();
      }
 else       if (node instanceof DBConnectionRepNode) {
        if (!isSupportedConnection(node)) {
          return node.getObject().getLabel() + "String_Node_Str";
        }
 else {
          return node.getLabel() + "String_Node_Str" + node.getObject().getVersion();
        }
      }
 else       if (node instanceof DBCatalogRepNode) {
        String catalogName=node.getObject().getLabel();
        IPath catalogPath=new Path(catalogName);
        catalogName=catalogPath.removeFileExtension().lastSegment();
        return catalogName;
      }
 else       if (node instanceof AnalysisFolderRepNode) {
        if (node instanceof AnalysisSubFolderRepNode) {
          AnalysisSubFolderRepNode anaSubNode=(AnalysisSubFolderRepNode)node;
          if (node.getObject() == null) {
            return DefaultMessagesImpl.getString("String_Node_Str") + anaSubNode.getCount();
          }
          return anaSubNode.getLabelWithCount();
        }
        AnalysisFolderRepNode anaNode=(AnalysisFolderRepNode)node;
        return anaNode.getLabelWithCount();
      }
 else       if (node instanceof ReportFolderRepNode) {
        if (node instanceof ReportSubFolderRepNode) {
          ReportSubFolderRepNode repSubNode=(ReportSubFolderRepNode)node;
          if (!ReportSubFolderType.SUB_FOLDER.equals(repSubNode.getReportSubFolderType())) {
            return (String)node.getProperties(EProperties.LABEL) + repSubNode.getCount();
          }
          return repSubNode.getLabelWithCount();
        }
        ReportFolderRepNode repNode=(ReportFolderRepNode)node;
        return repNode.getLabelWithCount();
      }
 else       if (node instanceof PatternLanguageRepNode) {
        return node.getLabel();
      }
 else       if (node instanceof ReportFileRepNode || node instanceof ReportAnalysisRepNode) {
        return node.getLabel();
      }
      String label=node.getObject().getLabel();
      boolean startsWith=label.startsWith(DQStructureManager.PREFIX_TDQ);
      if (startsWith) {
        label=label.substring(4,label.length());
        return label;
      }
 else       if (label.equals(EResourceConstant.METADATA.getName())) {
        label=label.substring(0,1).toUpperCase() + label.substring(1);
        return label;
      }
      return node.getObject() == null ? PluginConstant.EMPTY_STRING : label;
    }
  }
 catch (  RuntimeException e) {
    int indexOf=e.getMessage().indexOf("String_Node_Str");
    if (indexOf > 0 && PluginChecker.isOnlyTopLoaded()) {
      String errorMessage=e.getMessage().substring(indexOf);
      MessageDialog.openWarning(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(),DefaultMessagesImpl.getString("String_Node_Str"),errorMessage);
    }
 else {
      log.error(e);
    }
  }
  String text=super.getText(element);
  return PluginConstant.EMPTY_STRING.equals(text) ? DefaultMessagesImpl.getString("String_Node_Str") : text;
}

Fixed version (ground truth):
@Override public String getText(Object element){
  try {
    if (element != null && element instanceof IRepositoryNode) {
      IRepositoryNode node=(IRepositoryNode)element;
      if (node instanceof RecycleBinRepNode || node instanceof ExchangeCategoryRepNode || node instanceof ExchangeComponentRepNode) {
        return node.getLabel();
      }
 else       if (node instanceof DBConnectionSubFolderRepNode) {
        return ((DBConnectionSubFolderRepNode)node).getObject().getLabel();
      }
 else       if (node instanceof DBConnectionFolderRepNode) {
        return DefaultMessagesImpl.getString("String_Node_Str");
      }
 else       if (node instanceof DFConnectionSubFolderRepNode) {
        return ((DFConnectionSubFolderRepNode)node).getObject().getLabel();
      }
 else       if (node instanceof DFConnectionFolderRepNode) {
        return DefaultMessagesImpl.getString("String_Node_Str");
      }
 else       if (node instanceof MDMSchemaRepNode) {
        return ((MDMSchemaRepNode)node).getLabel();
      }
 else       if (node instanceof MDMConnectionSubFolderRepNode) {
        return ((MDMConnectionSubFolderRepNode)node).getObject().getLabel();
      }
 else       if (node instanceof MDMConnectionFolderRepNode) {
        return DefaultMessagesImpl.getString("String_Node_Str");
      }
 else       if (node instanceof DBTableFolderRepNode) {
        return ((DBTableFolderRepNode)node).getLabel();
      }
 else       if (node instanceof DBViewFolderRepNode) {
        return ((DBViewFolderRepNode)node).getLabel();
      }
 else       if (node instanceof DBColumnFolderRepNode) {
        return ((DBColumnFolderRepNode)node).getNodeName();
      }
 else       if (node instanceof DFColumnFolderRepNode) {
        return ((DFColumnFolderRepNode)node).getNodeName();
      }
 else       if (node instanceof DBTableRepNode) {
        return ((DBTableRepNode)node).getLabel();
      }
 else       if (node instanceof DBViewRepNode) {
        return ((DBViewRepNode)node).getLabel();
      }
 else       if (node instanceof DBColumnRepNode) {
        DBColumnRepNode columnNode=(DBColumnRepNode)node;
        return columnNode.getLabel() + LEFT + columnNode.getNodeDataType()+ RIGHT;
      }
 else       if (node instanceof DFColumnRepNode) {
        DFColumnRepNode dfColumnRepNode=(DFColumnRepNode)node;
        String nodeDataType=dfColumnRepNode.getNodeDataType();
        return dfColumnRepNode.getId() + LEFT + nodeDataType+ RIGHT;
      }
 else       if (node instanceof MDMXmlElementRepNode) {
        MDMXmlElementRepNode mdmColumnRepNode=(MDMXmlElementRepNode)node;
        String nodeDataType=mdmColumnRepNode.getNodeDataType();
        if (!PluginConstant.EMPTY_STRING.equals(nodeDataType)) {
          return mdmColumnRepNode.getTdXmlElementType().getName() + LEFT + nodeDataType+ RIGHT;
        }
        return mdmColumnRepNode.getTdXmlElementType().getName();
      }
 else       if (node instanceof AnalysisRepNode || node instanceof ReportRepNode || node instanceof SysIndicatorDefinitionRepNode|| node instanceof PatternRepNode|| node instanceof RuleRepNode|| node instanceof SourceFileRepNode|| node instanceof DFConnectionRepNode|| node instanceof MDMConnectionRepNode) {
        return node.getLabel() + "String_Node_Str" + node.getObject().getVersion();
      }
 else       if (node instanceof DBConnectionRepNode) {
        if (!isSupportedConnection(node)) {
          return node.getObject().getLabel() + "String_Node_Str";
        }
 else {
          return node.getLabel() + "String_Node_Str" + node.getObject().getVersion();
        }
      }
 else       if (node instanceof DBCatalogRepNode) {
        String catalogName=node.getObject().getLabel();
        IPath catalogPath=new Path(catalogName);
        catalogName=catalogPath.removeFileExtension().lastSegment();
        return catalogName;
      }
 else       if (node instanceof AnalysisFolderRepNode) {
        if (node instanceof AnalysisSubFolderRepNode) {
          AnalysisSubFolderRepNode anaSubNode=(AnalysisSubFolderRepNode)node;
          if (node.getObject() == null) {
            return DefaultMessagesImpl.getString("String_Node_Str") + anaSubNode.getCount();
          }
          return anaSubNode.getLabelWithCount();
        }
        AnalysisFolderRepNode anaNode=(AnalysisFolderRepNode)node;
        return anaNode.getLabelWithCount();
      }
 else       if (node instanceof ReportFolderRepNode) {
        if (node instanceof ReportSubFolderRepNode) {
          ReportSubFolderRepNode repSubNode=(ReportSubFolderRepNode)node;
          if (!ReportSubFolderType.SUB_FOLDER.equals(repSubNode.getReportSubFolderType())) {
            return (String)node.getProperties(EProperties.LABEL) + repSubNode.getCount();
          }
          return repSubNode.getLabelWithCount();
        }
        ReportFolderRepNode repNode=(ReportFolderRepNode)node;
        return repNode.getLabelWithCount();
      }
 else       if (node instanceof PatternLanguageRepNode) {
        return node.getLabel();
      }
 else       if (node instanceof ReportFileRepNode || node instanceof ReportAnalysisRepNode) {
        return node.getLabel();
      }
      String label=node.getObject().getLabel();
      boolean startsWith=label.startsWith(DQStructureManager.PREFIX_TDQ);
      if (startsWith) {
        label=label.substring(4,label.length());
        return label;
      }
 else       if (label.equals(EResourceConstant.METADATA.getName())) {
        label=label.substring(0,1).toUpperCase() + label.substring(1);
        return label;
      }
      return node.getObject() == null ? PluginConstant.EMPTY_STRING : label;
    }
  }
 catch (  MissingDriverException e) {
    if (PluginChecker.isOnlyTopLoaded()) {
      MessageDialog.openWarning(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(),DefaultMessagesImpl.getString("String_Node_Str"),e.getErrorMessage());
    }
 else {
      log.error(e,e);
    }
  }
  String text=super.getText(element);
  return PluginConstant.EMPTY_STRING.equals(text) ? DefaultMessagesImpl.getString("String_Node_Str") : text;
}