Skip to content

Commit 1b5f97f

Browse files
committed
Get param property resource instead of hardcoding path
1 parent 56fe008 commit 1b5f97f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/main/java/io/github/plastix/Params.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ public void loadParams() {
1919
Properties properties = new Properties();
2020
InputStream inputStream;
2121
try {
22-
inputStream = new FileInputStream("src/main/resources/params.properties");
22+
String paramPath = getClass().getResource("/params.properties").getPath();
23+
inputStream = new FileInputStream(paramPath);
2324
properties.load(inputStream);
2425
} catch(FileNotFoundException e) {
2526
System.out.println("No params file!");

0 commit comments

Comments
 (0)