Browse Source

Fixed error manager saying errors failed to send if the error was a new error

git-svn-id: http://svn.dmdirc.com/trunk@2289 00569f92-eb28-0410-84fd-f71c24880f
tags/0.5.1
Gregory Holmes 16 years ago
parent
commit
b61ed2b9b5
1 changed files with 3 additions and 3 deletions
  1. 3
    3
      src/com/dmdirc/logger/ErrorManager.java

+ 3
- 3
src/com/dmdirc/logger/ErrorManager.java View File

@@ -191,8 +191,8 @@ public final class ErrorManager implements Serializable {
191 191
             
192 192
             tries++;
193 193
             System.out.println(response);
194
-        } while(response.isEmpty() && !response.get(response.size() - 1).
195
-                equalsIgnoreCase("Error report submitted. Thank you.") 
194
+        } while((response.isEmpty() || !response.get(response.size() - 1).
195
+                equalsIgnoreCase("Error report submitted. Thank you.")) 
196 196
                 || tries >= 5);
197 197
         
198 198
         checkResponses(error, response);
@@ -201,7 +201,7 @@ public final class ErrorManager implements Serializable {
201 201
     /** Checks the responses and sets status accordingly. */
202 202
     private static void checkResponses(final ProgramError error,
203 203
             final List<String> response) {
204
-        if (response.isEmpty() && response.get(response.size() - 1).
204
+        if (!response.isEmpty() || response.get(response.size() - 1).
205 205
                 equalsIgnoreCase("Error report submitted. Thank you.")) {
206 206
             error.setReportStatus(ErrorReportStatus.FINISHED);
207 207
         } else {

Loading…
Cancel
Save