findbugs correction

Former-commit-id: 55b3830b5d31908e452ea6c688b0213aa04a7f41
This commit is contained in:
Jeremy Long
2015-05-11 20:31:36 -04:00
parent 659248ff22
commit 29c47e3e96

View File

@@ -429,10 +429,8 @@ public abstract class BaseDependencyCheckMojo extends AbstractMojo implements Ma
*/
protected File getCorrectOutputDirectory(MavenProject current) {
final Object obj = current.getContextValue(getOutputDirectoryContextKey());
if (obj != null) {
if (obj instanceof File) {
return (File) obj;
}
if (obj != null && obj instanceof File) {
return (File) obj;
}
File target = new File(current.getBuild().getDirectory());
if (target.getParentFile() != null && "target".equals(target.getParentFile().getName())) {