Fix checkstyle problem.

Signed-off-by: Yahor Berdnikau <egorr.berd@gmail.com>
This commit is contained in:
Yahor Berdnikau 2017-12-27 22:28:36 +01:00
parent ea3d36110d
commit 70c2e5213c
1 changed files with 2 additions and 2 deletions

View File

@ -48,8 +48,8 @@ class SubsonicApiSSLTest {
cert = (CertificateFactory.getInstance("X.509") cert = (CertificateFactory.getInstance("X.509")
.generateCertificate(certificatePemStream)) as X509Certificate .generateCertificate(certificatePemStream)) as X509Certificate
} }
val alias = cert?.subjectX500Principal?.name ?: val alias = cert?.subjectX500Principal?.name
throw IllegalStateException("Failed to load certificate") ?: throw IllegalStateException("Failed to load certificate")
trustStore.setCertificateEntry(alias, cert) trustStore.setCertificateEntry(alias, cert)
val tmf = TrustManagerFactory.getInstance("X509") val tmf = TrustManagerFactory.getInstance("X509")