Merge pull request 'Fix resourceBundleLoading' (#76) from fixMessageLoading into master
Reviewed-by: YoyoNow <jwsteam@nidido.de>
Dieser Commit ist enthalten in:
Commit
ea025bb424
@ -35,9 +35,11 @@ import java.util.ResourceBundle;
|
||||
public class Message {
|
||||
|
||||
private final String resourceBundleName;
|
||||
private final ClassLoader classLoader;
|
||||
|
||||
public Message(String resourceBundleName){
|
||||
public Message(String resourceBundleName, ClassLoader classLoader){
|
||||
this.resourceBundleName = resourceBundleName;
|
||||
this.classLoader = classLoader;
|
||||
}
|
||||
|
||||
/* Parsing input to a message */
|
||||
@ -61,7 +63,7 @@ public class Message {
|
||||
else
|
||||
locale = Locale.getDefault();
|
||||
|
||||
ResourceBundle resourceBundle = ResourceBundle.getBundle(resourceBundleName, locale);
|
||||
ResourceBundle resourceBundle = ResourceBundle.getBundle(resourceBundleName, locale, classLoader);
|
||||
String pattern = "";
|
||||
if(prefixed)
|
||||
pattern = resourceBundle.getObject("PREFIX") + " ";
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren