We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6f945fc commit 72f10e4Copy full SHA for 72f10e4
aws-datastore/src/main/java/com/amplifyframework/datastore/syncengine/Orchestrator.java
@@ -404,12 +404,11 @@ private void onApiSyncFailure(Throwable exception) {
404
return;
405
}
406
LOG.warn("API sync failed - transitioning to LOCAL_ONLY.", exception);
407
- Disposable subscription = Completable.fromAction(this::transitionToLocalOnly)
408
- .subscribe(
409
- () -> { /* no-op */ },
410
- error -> LOG.warn("Transition to LOCAL_ONLY failed.", error)
411
- );
412
- disposables.add(subscription);
+ try {
+ transitionToLocalOnly();
+ } catch (Exception error) {
+ LOG.warn("Transition to LOCAL_ONLY failed.", error);
+ }
413
414
415
private void disposeNetworkChanges() {
0 commit comments