Ignore:
Timestamp:
2010-05-15T21:57:19+02:00 (15 years ago)
Author:
jttt
Message:

Fix #4764 Fehler

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/tools/ExceptionUtil.java

    r3112 r3255  
    144144    /**
    145145     * Explains an OSM API exception because of a client timeout (HTTP 408).
    146      * 
     146     *
    147147     * @param e the exception
    148148     * @return the message
     
    159159    /**
    160160     * Replies a generic error message for an OSM API exception
    161      * 
     161     *
    162162     * @param e the exception
    163163     * @return the message
     
    278278
    279279    public static String explainSecurityException(OsmTransferException e) {
    280         String apiUrl = OsmApi.getOsmApi().getBaseUrl();
     280        String apiUrl = e.getUrl();
    281281        String host = tr("unknown");
    282282        try {
     
    301301
    302302    public static String explainNestedSocketException(OsmTransferException e) {
    303         String apiUrl = OsmApi.getOsmApi().getBaseUrl();
     303        String apiUrl = e.getUrl();
    304304        String message = tr("<html>Failed to open a connection to the remote server<br>" + "''{0}''.<br>"
    305305                + "Please check your internet connection.</html>", apiUrl);
     
    318318    public static String explainNestedIOException(OsmTransferException e) {
    319319        IOException ioe = getNestedException(e, IOException.class);
    320         String apiUrl = OsmApi.getOsmApi().getBaseUrl();
     320        String apiUrl = e.getUrl();
    321321        String message = tr("<html>Failed to upload data to or download data from<br>" + "''{0}''<br>"
    322322                + "due to a problem with transferring data.<br>" + "Details(untranslated): {1}</html>", apiUrl, ioe
     
    349349
    350350    public static String explainInternalServerError(OsmTransferException e) {
    351         String apiUrl = OsmApi.getOsmApi().getBaseUrl();
     351        String apiUrl = e.getUrl();
    352352        String message = tr("<html>The OSM server<br>" + "''{0}''<br>" + "reported an internal server error.<br>"
    353353                + "This is most likely a temporary problem. Please try again later.</html>", apiUrl);
     
    404404     */
    405405
    406     public static String explainNestedUnkonwnHostException(OsmTransferException e) {
    407         String apiUrl = OsmApi.getOsmApi().getBaseUrl();
     406    public static String explainNestedUnknownHostException(OsmTransferException e) {
     407        String apiUrl = e.getUrl();
    408408        String host = tr("unknown");
    409409        try {
     
    453453            return explainNestedSocketException(e);
    454454        if (getNestedException(e, UnknownHostException.class) != null)
    455             return explainNestedUnkonwnHostException(e);
     455            return explainNestedUnknownHostException(e);
    456456        if (getNestedException(e, IOException.class) != null)
    457457            return explainNestedIOException(e);
Note: See TracChangeset for help on using the changeset viewer.