Fix #6 Factory Null-tolerant for trusted certificate

This commit is contained in:
2016-12-21 20:22:26 +01:00
parent 3f7f88e14a
commit ea3b6d50cb
4 changed files with 10 additions and 3 deletions

View File

@ -131,7 +131,9 @@ public class HTTPVaultConnectorFactory extends VaultConnectorFactory {
* @since 0.4.0
*/
public HTTPVaultConnectorFactory withTrustedCA(Path cert) throws VaultConnectorException {
return withSslContext(createSslContext(cert));
if (cert != null)
return withSslContext(createSslContext(cert));
return this;
}
/**