mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-22 18:00:02 +01:00
Add 10s timeout to user facing CDSI requests.
This commit is contained in:
committed by
Greyson Parrelli
parent
8d20669e46
commit
36fc9aa82a
@@ -49,6 +49,7 @@ import org.whispersystems.signalservice.api.push.ServiceId;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.Optional;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
public class CommunicationActions {
|
||||
|
||||
@@ -303,7 +304,7 @@ public class CommunicationActions {
|
||||
|
||||
if (!recipient.isRegistered() || !recipient.hasServiceId()) {
|
||||
try {
|
||||
ContactDiscovery.refresh(activity, recipient, false);
|
||||
ContactDiscovery.refresh(activity, recipient, false, TimeUnit.SECONDS.toMillis(10));
|
||||
recipient = Recipient.resolved(recipient.getId());
|
||||
} catch (IOException e) {
|
||||
Log.w(TAG, "[handlePotentialSignalMeUrl] Failed to refresh directory for new contact.");
|
||||
|
||||
Reference in New Issue
Block a user