fix displayLanguage representation
This commit is contained in:
parent
333ffc340e
commit
b4764afd1f
|
@ -51,15 +51,14 @@ public class AcceptLanguageHeader {
|
|||
|
||||
@Override
|
||||
public String toString() {
|
||||
if (value == 0) {
|
||||
if (value == 1) {
|
||||
return lang;
|
||||
} else {
|
||||
return lang+"; q="+Double.toString(value);
|
||||
return lang+"; q="+(String.format("%.6f", value).replaceAll("(\\.\\d+?)0*$", "$1")); //Double.toString(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private String source;
|
||||
private List<LanguagePreference> langs = new ArrayList<>();
|
||||
private boolean doWildcard;
|
||||
|
|
Loading…
Reference in New Issue