Simplified boundary exception

This commit is contained in:
M66B 2021-06-18 16:55:22 +02:00
parent 877d1f1764
commit 02ccc2f8b7
1 changed files with 6 additions and 4 deletions

View File

@ -493,12 +493,14 @@ public class BoundaryCallbackMessages extends PagedList.BoundaryCallback<TupleMe
return search(false, browsable.keywords, protocol, state);
}
} catch (Throwable ex) {
String msg;
ProtocolException pex;
if (ex instanceof ProtocolException)
msg = context.getString(R.string.title_service_auth, account.host + ": " + ex.getMessage());
pex = new ProtocolException(
context.getString(R.string.title_service_auth,
account.host + ": " + ex.getMessage()),
ex.getCause());
else
msg = "Search " + account.host;
ProtocolException pex = new ProtocolException(msg, ex);
pex = new ProtocolException("Search " + account.host, ex);
Log.e(pex);
throw pex;
}