fixed classifier NPE
This commit is contained in:
2
pom.xml
2
pom.xml
@@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<groupId>com.inteligr8.alfresco</groupId>
|
<groupId>com.inteligr8.alfresco</groupId>
|
||||||
<artifactId>amp-maven-plugin</artifactId>
|
<artifactId>amp-maven-plugin</artifactId>
|
||||||
<version>1.0-SNAPSHOT</version>
|
<version>1.1-SNAPSHOT</version>
|
||||||
<packaging>maven-plugin</packaging>
|
<packaging>maven-plugin</packaging>
|
||||||
|
|
||||||
<name>A Maven plugin to generate AMP files</name>
|
<name>A Maven plugin to generate AMP files</name>
|
||||||
|
@@ -200,14 +200,18 @@ public class AmpMojo extends AbstractMojo implements ArtifactResolutionCallback
|
|||||||
}
|
}
|
||||||
|
|
||||||
private File getModuleFile() throws MojoExecutionException {
|
private File getModuleFile() throws MojoExecutionException {
|
||||||
String moduleJarFile = this.injectClassifier(this.moduleJarFile);
|
if (this.classifier != null) {
|
||||||
File jarFile = new File(moduleJarFile);
|
String moduleJarFile = this.injectClassifier(this.moduleJarFile);
|
||||||
if (!jarFile.exists()) {
|
File jarFile = new File(moduleJarFile);
|
||||||
jarFile = new File(this.moduleJarFile);
|
if (jarFile.exists())
|
||||||
if (!jarFile.exists())
|
return jarFile;
|
||||||
throw new MojoExecutionException("The module JAR file does not exist: " + this.moduleJarFile);
|
}
|
||||||
}
|
|
||||||
return jarFile;
|
File jarFile = new File(this.moduleJarFile);
|
||||||
|
if (jarFile.exists())
|
||||||
|
return jarFile;
|
||||||
|
|
||||||
|
throw new MojoExecutionException("The module JAR file does not exist: " + this.moduleJarFile);
|
||||||
}
|
}
|
||||||
|
|
||||||
private File getModulePropertyFile() throws MojoExecutionException {
|
private File getModulePropertyFile() throws MojoExecutionException {
|
||||||
|
Reference in New Issue
Block a user