mirror of https://github.com/M66B/FairEmail.git
Refactoring
This commit is contained in:
parent
a7ea56b5a0
commit
ff11c6a9e8
|
@ -90,7 +90,7 @@ public class BoundaryCallbackMessages extends PagedList.BoundaryCallback<TupleMe
|
|||
|
||||
void onLoaded(int fetched);
|
||||
|
||||
void onError(@NonNull Throwable ex);
|
||||
void onException(@NonNull Throwable ex);
|
||||
}
|
||||
|
||||
BoundaryCallbackMessages(Context context, long folder, boolean server, String query, int pageSize) {
|
||||
|
@ -151,7 +151,7 @@ public class BoundaryCallbackMessages extends PagedList.BoundaryCallback<TupleMe
|
|||
handler.post(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
intf.onError(ex);
|
||||
intf.onException(ex);
|
||||
}
|
||||
});
|
||||
} finally {
|
||||
|
|
|
@ -2725,7 +2725,7 @@ public class FragmentMessages extends FragmentBase implements SharedPreferences.
|
|||
}
|
||||
|
||||
@Override
|
||||
public void onError(Throwable ex) {
|
||||
public void onException(@NonNull Throwable ex) {
|
||||
if (getLifecycle().getCurrentState().isAtLeast(Lifecycle.State.RESUMED))
|
||||
if (ex instanceof IllegalStateException) {
|
||||
Snackbar snackbar = Snackbar.make(view, ex.getMessage(), Snackbar.LENGTH_LONG);
|
||||
|
|
Loading…
Reference in New Issue