Uploaded image for project: 'Maven'
  1. Maven
  2. MNG-6081

Log refactoring - Method Invocation Replaced By Variable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.3.9
    • Fix Version/s: 3.5.0-alpha-1, 3.5.0
    • Component/s: core
    • Labels:
      None

      Description

      Method Invocation Replaced By Variable
      In file: apache-maven-3.3.9/maven-compat/src/main/java/org/apache/maven/artifact/resolver/DebugResolutionListener.java

      from line 70:

      String keptVersion = kept.getVersion();
      
      if ( omittedVersion != null ? !omittedVersion.equals( keptVersion ) : keptVersion != null )
      {
          logger.debug( indent + omitted + " (removed - nearer found: " + kept.getVersion() + ")" );
      }
      

      the "kept.getVersion()" can be replaced with "keptVersion" for the sake of simplicity and readability.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                michael-o Michael Osipov
                Reporter:
                chenfsd Nemo Chen
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: