GrantPSpencer commented on code in PR #2583:
URL: https://github.com/apache/helix/pull/2583#discussion_r1283706356


##########
helix-rest/src/main/java/org/apache/helix/rest/server/resources/helix/ClusterAccessor.java:
##########
@@ -321,8 +322,13 @@ public Response updateCluster(@PathParam("clusterId") 
String clusterId,
           customFieldsMap =
               OBJECT_MAPPER.readValue(content, new 
TypeReference<HashMap<String, String>>() {
               });
-          // content is given as a KV mapping. Nullify content
+          // content is given as a KV mapping. Nullify content unless 
(case-insensitive) reason key present in map
           content = null;
+          for (Map.Entry<String, String> entry : customFieldsMap.entrySet()) {
+            if ("reason".equals(entry.getKey().toLowerCase(Locale.ENGLISH))) {

Review Comment:
   Habit from old team. I've updated to use equalsIgnoreCase:
   
   if ("reason".**equalsIgnoreCase**(entry.getKey())) {



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to