You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pr@cassandra.apache.org by GitBox <gi...@apache.org> on 2022/11/11 11:21:43 UTC

[GitHub] [cassandra] Claudenw commented on a diff in pull request #2001: CASSANDRA-17878 4.1 simplified patch

Claudenw commented on code in PR #2001:
URL: https://github.com/apache/cassandra/pull/2001#discussion_r1020128942


##########
src/java/org/apache/cassandra/cql3/statements/PropertyDefinitions.java:
##########
@@ -97,17 +98,29 @@ public Boolean hasProperty(String name)
         return properties.containsKey(name);
     }
 
-    public String getString(String key, String defaultValue) throws SyntaxException
+    public static boolean parseBoolean(String key, String value) throws SyntaxException
     {
-        String value = getSimple(key);
-        return value != null ? value : defaultValue;
+        if (null == value)
+            throw new IllegalArgumentException("value argument can't be null");

Review Comment:
   Shouldn't this exception mention the key name?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: pr-unsubscribe@cassandra.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@cassandra.apache.org
For additional commands, e-mail: pr-help@cassandra.apache.org