diff --git a/client/trino-client/src/main/java/io/trino/client/OkHttpUtil.java b/client/trino-client/src/main/java/io/trino/client/OkHttpUtil.java index 77c5121b3943..0ea2481b6fcc 100644 --- a/client/trino-client/src/main/java/io/trino/client/OkHttpUtil.java +++ b/client/trino-client/src/main/java/io/trino/client/OkHttpUtil.java @@ -305,7 +305,7 @@ else if (osName.contains("Mac")) { KeyStore trustStore; if (systemTrustStoreType.isPresent()) { - trustStore = KeyStore.getInstance(systemTrustStoreType.orElseGet(KeyStore::getDefaultType)); + trustStore = KeyStore.getInstance(systemTrustStoreType.get()); trustStore.load(null, null); } else {