Skip to content

Commit

Permalink
Adjust exception messages
Browse files Browse the repository at this point in the history
Signed-off-by: Václav Muzikář <[email protected]>
  • Loading branch information
vmuzikar committed Aug 9, 2024
1 parent 51b0d79 commit 5494acb
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -146,10 +146,10 @@ public static void validateConfig() {
try {
TlsUtils.computeTrustOptions(config, config.trustStorePassword);
} catch (IOException e) {
throw new PropertyException(Messages.httpsConfigurationNotSet());
throw new IllegalArgumentException("Failed to load 'https-trust-store' material.", e);
} catch (IllegalArgumentException e) {
throw new IllegalArgumentException("Unable to determine 'https-trust-store-type' automatically. " +
"Adjust the file extension or specify the property.");
"Adjust the file extension or specify the property.", e);
}
}

Expand All @@ -170,10 +170,10 @@ public static void validateConfig() {
try {
TlsUtils.computeKeyStoreOptions(config, config.keyStorePassword, config.keyStoreAliasPassword);
} catch (IOException e) {
throw new PropertyException(Messages.httpsConfigurationNotSet());
throw new IllegalArgumentException("Failed to load 'https-key-store' material.", e);
} catch (IllegalArgumentException e) {
throw new IllegalArgumentException("Unable to determine 'https-key-store-type' automatically. " +
"Adjust the file extension or specify the property.");
"Adjust the file extension or specify the property.", e);
}
}

Expand Down

0 comments on commit 5494acb

Please sign in to comment.