fix npe with japan bank account
This commit is contained in:
parent
5d5eb649c6
commit
8f310469da
1 changed files with 2 additions and 10 deletions
|
@ -18,8 +18,7 @@
|
||||||
package haveno.core.payment;
|
package haveno.core.payment;
|
||||||
|
|
||||||
import com.google.common.collect.ImmutableMap;
|
import com.google.common.collect.ImmutableMap;
|
||||||
import com.google.inject.Inject;
|
import haveno.core.trade.HavenoUtils;
|
||||||
import haveno.core.user.Preferences;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
@ -47,13 +46,6 @@ import java.util.Map;
|
||||||
|
|
||||||
public class JapanBankData {
|
public class JapanBankData {
|
||||||
|
|
||||||
private static String userLanguage;
|
|
||||||
|
|
||||||
@Inject
|
|
||||||
JapanBankData(Preferences preferences) {
|
|
||||||
userLanguage = preferences.getUserLanguage();
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Returns the main list of ~500 banks in Japan with bank codes,
|
Returns the main list of ~500 banks in Japan with bank codes,
|
||||||
but since 90%+ of people will be using one of ~30 major banks,
|
but since 90%+ of people will be using one of ~30 major banks,
|
||||||
|
@ -793,7 +785,7 @@ public class JapanBankData {
|
||||||
// don't localize these strings into all languages,
|
// don't localize these strings into all languages,
|
||||||
// all we want is either Japanese or English here.
|
// all we want is either Japanese or English here.
|
||||||
public static String getString(String id) {
|
public static String getString(String id) {
|
||||||
boolean ja = userLanguage.equals("ja");
|
boolean ja = HavenoUtils.preferences.getUserLanguage().equals("ja");
|
||||||
|
|
||||||
switch (id) {
|
switch (id) {
|
||||||
case "bank":
|
case "bank":
|
||||||
|
|
Loading…
Reference in a new issue