Localize service error messages

This commit is contained in:
M66B
2020-03-11 14:25:09 +01:00
parent 03cfeb6801
commit 5e6f2e4599
2 changed files with 4 additions and 2 deletions

View File

@@ -340,7 +340,7 @@ public class EmailService implements AutoCloseable {
} catch (MailConnectException ex) {
if (ConnectionHelper.vpnActive(context)) {
MailConnectException mex = new MailConnectException(new SocketConnectException(
"The might be caused by the VPN in use",
context.getString(R.string.title_service_vpn),
new Exception(),
ex.getHost(),
ex.getPort(),
@@ -351,7 +351,7 @@ public class EmailService implements AutoCloseable {
throw ex;
} catch (MessagingException ex) {
if (port == 995 && !("pop3".equals(protocol) || "pop3s".equals(protocol)))
throw new MessagingException("Please double check the port number", ex);
throw new MessagingException(context.getString(R.string.title_service_port), ex);
else
throw ex;
}