Uploaded image for project: 'Apache Taverna'
  1. Apache Taverna
  2. TAVERNA-1019

Condition that always returns true

    XMLWordPrintableJSON

Details

    • Bug
    • Status: To Do
    • Trivial
    • Resolution: Unresolved
    • None
    • None
    • Taverna Workbench
    • None

    Description

      Hi

      In a recent snapshot from Github mirror for incubator-taverna-workbench, I've found following suspicious code in taverna-edits-impl/src/main/java/org/apache/taverna/workbench/edits/impl/menu/AbstractUndoAction.java

      132                 public void notify(Observable<EditManagerEvent> sender,
      133                                 EditManagerEvent message) throws Exception {
      134                         if (!(message instanceof AbstractDataflowEditEvent))
      135                                 return;
      136                         AbstractDataflowEditEvent dataflowEdit = (AbstractDataflowEditEvent) message;
      137                         if (dataflowEdit.getDataFlow().equals(dataflowEdit.getDataFlow()))
      138                                 // It's an edit that could effect our undoability
      139                                 updateStatus();
      140                 }
      

      In Line 137, equals compares the same expression. If this is intended, it might not be an issue but wanted to report just in case. Thanks!

      Attachments

        Activity

          People

            Unassigned Unassigned
            lifove JC
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: