mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2024-12-28 03:57:33 +01:00
Change Locale#getMessage to using HashMap#getOrDefault
This commit is contained in:
parent
2a5a671786
commit
a1e87089bb
@ -316,8 +316,7 @@ public class Locale implements Closeable {
|
||||
}
|
||||
|
||||
public Message getMessage(Msg msg) {
|
||||
Message message = messages.get(msg);
|
||||
return message != null ? message : new Message("");
|
||||
return messages.getOrDefault(msg, new Message(""));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
Reference in New Issue
Block a user