Add logging when checking SMTP server settings fails
This commit is contained in:
parent
1ac7d1bb3d
commit
7e5cbf124e
1 changed files with 4 additions and 0 deletions
|
@ -665,12 +665,16 @@ class SmtpTransport(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Suppress("TooGenericExceptionCaught")
|
||||||
@Throws(MessagingException::class)
|
@Throws(MessagingException::class)
|
||||||
fun checkSettings() {
|
fun checkSettings() {
|
||||||
ensureClosed()
|
ensureClosed()
|
||||||
|
|
||||||
try {
|
try {
|
||||||
open()
|
open()
|
||||||
|
} catch (e: Exception) {
|
||||||
|
Timber.e(e, "Error while checking server settings")
|
||||||
|
throw e
|
||||||
} finally {
|
} finally {
|
||||||
close()
|
close()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue