Affects PMD Version: 6.11.0
Rule: UselessParentheses
Code Sample demonstrating the issue:
throw new IllegalArgumentException(String.format(
"Unsupported client with class '%s' given",
(discordClient == null) ? null : discordClient.getClass()));
Additionally, should we add properties to allow whitelisting some scenarios, such as this one?
while ((result instanceof CompletionException) && (cause != null)) {
result = cause;
cause = result.getCause();
}
Running PMD through: Gradle
Affects PMD Version: 6.11.0
Rule: UselessParentheses
Code Sample demonstrating the issue:
Additionally, should we add properties to allow whitelisting some scenarios, such as this one?
Running PMD through: Gradle