This commit is contained in:
GregTCLTK 2020-02-03 11:54:31 +01:00
parent b64fa332eb
commit 4bdbb6e0b9
No known key found for this signature in database
GPG key ID: A91BADE5C070FF67

View file

@ -28,7 +28,6 @@ import org.apache.maven.model.io.xpp3.MavenXpp3Reader;
import org.codehaus.plexus.util.xml.pull.XmlPullParserException; import org.codehaus.plexus.util.xml.pull.XmlPullParserException;
import javax.annotation.Nonnull; import javax.annotation.Nonnull;
import java.io.FileReader;
import java.io.IOException; import java.io.IOException;
import java.util.Random; import java.util.Random;
@ -51,7 +50,7 @@ public class MentionListener extends ListenerAdapter {
MavenXpp3Reader reader = new MavenXpp3Reader(); MavenXpp3Reader reader = new MavenXpp3Reader();
Model model = null; Model model = null;
try { try {
model = reader.read(new FileReader("pom.xml")); model = reader.read(this.getClass().getClassLoader().getResourceAsStream("pom.xml"));
} catch (IOException | XmlPullParserException ex) { } catch (IOException | XmlPullParserException ex) {
ex.printStackTrace(); ex.printStackTrace();
} }