Added {NAME} replacement in database location
This commit is contained in:
parent
4415112ea3
commit
3f2a31fa5e
@ -188,7 +188,9 @@ public abstract class JavaPlugin implements Plugin {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private String replaceDatabaseString(String input) {
|
private String replaceDatabaseString(String input) {
|
||||||
return input.replaceAll("\\{DIR\\}", getDataFolder().getPath().replaceAll("\\\\", "/"));
|
input = input.replaceAll("\\{DIR\\}", getDataFolder().getPath().replaceAll("\\\\", "/") + "/");
|
||||||
|
input = input.replaceAll("\\{NAME\\}", getDescription().getName().replaceAll("[^\\w_-]", ""));
|
||||||
|
return input;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user