Fix bug in ignoring svr errors in account deletion flow
This commit is contained in:
parent
f60c9f2a15
commit
d6e03f50b9
|
@ -989,14 +989,14 @@ public class AccountsManager {
|
||||||
device.getId())))
|
device.getId())))
|
||||||
.toList();
|
.toList();
|
||||||
CompletableFuture<Void> deleteBackupFuture = secureValueRecovery2Client.deleteBackups(account.getUuid())
|
CompletableFuture<Void> deleteBackupFuture = secureValueRecovery2Client.deleteBackups(account.getUuid())
|
||||||
.exceptionally(exception -> {
|
.exceptionally(ExceptionUtils.exceptionallyHandler(SecureValueRecoveryException.class, exception -> {
|
||||||
final List<String> svrStatusCodesToIgnore = dynamicConfigurationManager.getConfiguration().getSvrStatusCodesToIgnoreForAccountDeletion();
|
final List<String> svrStatusCodesToIgnore = dynamicConfigurationManager.getConfiguration().getSvrStatusCodesToIgnoreForAccountDeletion();
|
||||||
if (exception instanceof SecureValueRecoveryException e && svrStatusCodesToIgnore.contains(e.getStatusCode())) {
|
if (svrStatusCodesToIgnore.contains(exception.getStatusCode())) {
|
||||||
logger.warn("Failed to delete backup for account: " + account.getUuid(), exception);
|
logger.warn("Failed to delete backup for account: " + account.getUuid(), exception);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
throw new CompletionException(exception);
|
throw new CompletionException(exception);
|
||||||
});
|
}));
|
||||||
|
|
||||||
return CompletableFuture.allOf(
|
return CompletableFuture.allOf(
|
||||||
secureStorageClient.deleteStoredData(account.getUuid()),
|
secureStorageClient.deleteStoredData(account.getUuid()),
|
||||||
|
|
Loading…
Reference in New Issue