Ignore:
Timestamp:
2015-05-21T01:18:35+02:00 (9 years ago)
Author:
Don-vip
Message:

When doing a String.toLowerCase()/toUpperCase() call, use a Locale. This avoids problems with certain locales, i.e. Lithuanian or Turkish. See PMD UseLocaleWithCaseConversions rule and String.toLowerCase() javadoc.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/osm/OsmPrimitive.java

    r8395 r8404  
    1515import java.util.LinkedList;
    1616import java.util.List;
     17import java.util.Locale;
    1718import java.util.Map;
    1819import java.util.Set;
     
    13421343    public Object getTemplateValue(String name, boolean special) {
    13431344        if (special) {
    1344             String lc = name.toLowerCase();
     1345            String lc = name.toLowerCase(Locale.ENGLISH);
    13451346            if (SPECIAL_VALUE_ID.equals(lc))
    13461347                return getId();
Note: See TracChangeset for help on using the changeset viewer.