mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-05-04 15:35:38 +01:00
Use AttachmentsV2 if the resumable upload link from V3 becomes corrupted.
This commit is contained in:
+7
@@ -0,0 +1,7 @@
|
||||
package org.whispersystems.signalservice.api.push.exceptions;
|
||||
|
||||
public class NonSuccessfulResumableUploadResponseCodeException extends NonSuccessfulResponseCodeException {
|
||||
public NonSuccessfulResumableUploadResponseCodeException(int code, String s) {
|
||||
super(code, s);
|
||||
}
|
||||
}
|
||||
+2
-1
@@ -59,6 +59,7 @@ import org.whispersystems.signalservice.api.push.exceptions.MalformedResponseExc
|
||||
import org.whispersystems.signalservice.api.push.exceptions.MissingConfigurationException;
|
||||
import org.whispersystems.signalservice.api.push.exceptions.NoContentException;
|
||||
import org.whispersystems.signalservice.api.push.exceptions.NonSuccessfulResponseCodeException;
|
||||
import org.whispersystems.signalservice.api.push.exceptions.NonSuccessfulResumableUploadResponseCodeException;
|
||||
import org.whispersystems.signalservice.api.push.exceptions.NotFoundException;
|
||||
import org.whispersystems.signalservice.api.push.exceptions.ProofRequiredException;
|
||||
import org.whispersystems.signalservice.api.push.exceptions.PushNetworkException;
|
||||
@@ -1374,7 +1375,7 @@ public class PushServiceSocket {
|
||||
} else if (response.code() == 404) {
|
||||
throw new ResumeLocationInvalidException();
|
||||
} else {
|
||||
throw new NonSuccessfulResponseCodeException(response.code(), "Response: " + response);
|
||||
throw new NonSuccessfulResumableUploadResponseCodeException(response.code(), "Response: " + response);
|
||||
}
|
||||
} finally {
|
||||
synchronized (connections) {
|
||||
|
||||
Reference in New Issue
Block a user