Ignore:
Timestamp:
2017-10-30T23:58:23+01:00 (2 years ago)
Author:
Don-vip
Message:

remove legacy properties (pluginmanager.warntime and osm-server.atomic-upload) kind-of-deprecated 8 years ago in r2569 and r2924

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/io/UploadStrategy.java

    r12894 r13064  
    66import java.util.Locale;
    77
    8 import org.openstreetmap.josm.data.PreferencesUtils;
    98import org.openstreetmap.josm.spi.preferences.Config;
    109import org.openstreetmap.josm.tools.Logging;
     
    6867     * Replies the upload strategy currently configured in the preferences.
    6968     *
    70      * First checks for the preference key <pre>osm-server.upload-strategy</pre>. If not
    71      * present, checks for the legacy preference key <pre>osm-server.atomic-upload</pre>.
     69     * Checks for the preference key <pre>osm-server.upload-strategy</pre>.
    7270     *
    73      * If both are missing or if the preference value is illegal, {@link #DEFAULT_UPLOAD_STRATEGY}
     71     * If missing or if the preference value is illegal, {@link #DEFAULT_UPLOAD_STRATEGY}
    7472     * is replied.
    7573     *
     
    7977        String v = Config.getPref().get("osm-server.upload-strategy", null);
    8078        if (v == null) {
    81             // legacy support. Until 12/2009 we had osm-server.atomic-upload only.
    82             // If we still find "osm-server.atomic-upload" we use it and remove it.
    83             // When the preferences are saved the next time, "osm-server.upload-strategy"
    84             // will be inserted.
    85             v = Config.getPref().get("osm-server.atomic-upload", null);
    86             if (v != null) {
    87                 PreferencesUtils.removeFromList(Config.getPref(), "osm-server.atomic-upload", v);
    88             } else {
    89                 v = "";
    90             }
    91             v = v.trim().toLowerCase(Locale.ENGLISH);
    92             if ("true".equals(v))
    93                 return SINGLE_REQUEST_STRATEGY;
    94             else if ("false".equals(v))
    95                 return INDIVIDUAL_OBJECTS_STRATEGY;
    96             else
    97                 return DEFAULT_UPLOAD_STRATEGY;
     79            return DEFAULT_UPLOAD_STRATEGY;
    9880        }
    9981        UploadStrategy strategy = fromPreference(v);
Note: See TracChangeset for help on using the changeset viewer.