A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/pmd/pmd/issues/2569 below:

False negative for methods returning Strings · Issue #2569 · pmd/pmd · GitHub

Affects PMD Version:
6.24.0

Description:

Rule LiteralsFirstInComparisons does not flag the following :

package com.javacodegeeks.patterns.chainofresponsibility;

public class ImageFileHandler implements Handler {
    @Override
  public void process(File file) {
    if (file.getFileType().equals("image")) { // violation expected
      System.out.println("Process and saving image file... by ");
      return;
    }
  }

}

Running PMD through: [CLI | Ant ]


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4